-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v2.0 #24
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
… Update unit tests accordingly.
…ogHandler class and format traceback functionality.
… (property list file).
… to follow consistent pattern.
…d at a child logger level.
… handled appropriately.
…urn the latest cached dataset available.
ball42
approved these changes
Jan 22, 2025
# Conflicts: # Makefile # README.md # docs/_static/css/custom.css # docs/user/customize_reports.rst # pyproject.toml
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What's Changed
Patcher v2.0 brings a few new 'breaking' changes.
Subcommands
Entry point is now split into three separate commands:
export
,reset
, andanalyze
:export
exports patch management data into Excel and PDF reports, with same options that can be passed (e.g.,sort
,omit
, etc.)reset
resets end-user configuration settings by kind (full, creds, UI or cache)analyze
analyzes the last exported dataset by passed criteria, returns a formatted table tostdout
.Data Caching
The
ExcelReport
class has been refactored into a more robustDataManager
class. It now handles automatic caching of patch reports using pickle files (*.pkl
). The analyze command automatically gathers the latest exported patch report so end-users do not have to pass one. The analyze command does support providing a separate or alternate patch report for analysis by passing the--excel-file
option.Data caching can be disabled at any time by passing the
--disable-cache
flag to any command.Logging and Error Handling
Logging configuration and custom exceptions have been overhauled. Previous versions 'over-logged' in the sense low-level functions/methods would log messages, resulting in duplicate log entries. Log entries are now propagated to callers, and tracebacks properly formatted to log files. Log entries with potentially sensitive information (JSS URL, API credentials, etc) are sanitized before being written to the log file for security purposes.
Tracebacks no longer show in
stdout
/stderr
unless the global--debug
flag is passed. Error handling has been improved to show clearly formatted errors instead of long confusing tracebacks. Exit codes have been strategically implemented depending on type of issue encountered.Minor improvements
--help
or-h
:Each command has a help menu that can be shown using
patcherctl <command> --help
.