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.
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
Add config_overrides argument to initializer of MergerConfig #225
Add config_overrides argument to initializer of MergerConfig #225
Changes from all commits
13a3038
fe2bd4c
7ec2e51
741d6f5
cc5812a
db4e75b
8fc4344
be67e61
edcbb5b
8501093
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just noticed the overrides will only apply when a config file has been provided. Wasn't the original goal to entirely avoid using an external config file for API users? Using an override mechanism can get us there, but only if it also handles the case of there being no config file to start with. Having said that, such a change blows open the scope of this change because the change would have to also cover the rest of the interface provided by
ConfigParser
(like.sections()
, et al).This feels like we're missing the goal. Will you be happy with the compromise you've added here or should we dig deeper into this to provide a solution that actually makes the config file optional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is just a case of not fixing an indent after making a change. Everything should work just fine by un-indenting those lines because even if the config file doesn't exist, we still use ConfigParser, adding it as a class member only if we added the overrides to it (by using
sections()
).Though your comment made me realize that my tests should have caught this earlier, so I checked out my tests and realized that anything specified inself.args
has a higher priority than my changes, which I think misses the mark. I'll take a deeper look into fixing this when I have a bit more time to update everything, but I'll push some changes to the tests soon to illustrate the issue.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Disregard that last part, turns out it works just fine based on the tests I added. I added a fix and some tests for the fix.