fix: move --update-<importer> args into their service option groups - #165
Open
Sanjays2402 wants to merge 1 commit into
Open
fix: move --update-<importer> args into their service option groups#165Sanjays2402 wants to merge 1 commit into
Sanjays2402 wants to merge 1 commit into
Conversation
The --update-grafana, --update-postgres and --update-bigquery options were added directly to the analyze subparser, so argparse placed them in the generic 'options:' section of 'otava analyze --help' rather than alongside the service options they belong to. The subparser already inherits the Grafana/PostgreSQL/BigQuery option groups from the shared parent parser, so this adds a small config.argument_group() helper that looks up an existing group by title, and registers each --update-<importer> flag on its corresponding service group. Parsing behaviour is unchanged; only the help output grouping differs. The existing golden help-output assertions in tests/cli_help_test.py are updated to the new placement and fail without this change.
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.
Closes #120
--update-grafana,--update-postgresand--update-bigqueryare added directly to theanalyzesubparser, so argparse lists them under the genericoptions:section instead of next to the service options they configure.The subparser already inherits the Grafana/PostgreSQL/BigQuery groups from the shared parent parser, so this adds a small
config.argument_group()helper that looks up an existing group by title and registers each flag on the matching group. Parsing behaviour is unchanged — only the help layout differs. The golden help assertions intests/cli_help_test.pyare updated accordingly and fail without the fix.