Added flexible output formatting and CSV export to showaccounting#556
Merged
Conversation
* Specifying number of formatting decimals * Formatting numbers due to local settings * SI byte units * CSV output format
Add tests for the decimals, si_byte_format, and locale_format parameters added to human_readable_filesize and get_usage, verify the updated ext_users_report format (parsed name/email/org/country via distinguished_name_to_user), and close several behavioural gaps: - get_usage returns None when no accounting file exists - ext users appear in a full dump but are suppressed when a targeted userlist is given that does not include them, and re-exposed when they are listed explicitly - freeze quota files are ignored when site_enable_freeze is False - human_readable_filesize(1) boundary case
Contributor
jonasbardino
left a comment
There was a problem hiding this comment.
Looks good overall. No obvious show-stoppers but a few things to address or consider. Please just comment and re-request review from me if/when you need the approval.
* Changed '-s' to '-o FORMAT' * Use the python csv module to generate the 'csv' output. Thanks @jonasbardino
Contributor
Author
|
Thanks for the review @jonasbardino I've addressed all comments |
This file contains hidden or 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
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.
Add flexible output formatting and CSV export to showaccounting
This PR extends showaccounting with several output formatting options and a CSV export mode, making it more useful for both operational and management reporting.
New features:
useridstring