Don't print config content by default #146
Merged
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.
This is very petty...
The config module is currently set up to print the config contents by default each time a new config is loaded. In the pipeline startup the config content is repeated 3 times resulting in a huge wall of redundant text. This also clouds the logging for failed tests etc. and is generally not useful.
The first get_config invocation in the pipeline is easy to find, but I haven't located the subsequent 2 calls that trigger re-printing of the same content...
Instead of mucking about in the prod-pipes codebase to track down the exact calls, how do you feel about treating this at source - alter the default behaviour not to print to logging, then set
get_config(True)
as a deliberate action (e.g. the first time the config is loaded, then never again)Proposal generally approved on Slack: https://centrepopgen.slack.com/archives/C018KFBCR1C/p1700002730474369