-
Notifications
You must be signed in to change notification settings - Fork 16
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
Reconsider how multi-valued options combine between the config file and the command-line? #328
Comments
From #365 (comment):
TL;DR: Yes, I think I agree with @Nour-Mws here. There are many similar questions of this kind that can be asked:
Taking a step back, I think of these questions as instances of a pattern of a few, more general questions. Since our settings are implemented as a cascade/layering of
For now, we've answered the questions like this:
I'm happy for us to continue like this, but I also see that there is some demand for extending/combining some directives instead always/only replacing. If we were to add functionality for this, I think we should do so very carefully and deliberately. Here is an example of what we could consider doing (a rough sketch and I'm not sure about many things here):
|
How should multi-valued options on the command-line (e.g.
--code foo.py bar.py
) combine with corresponding multi-valued options from the config file (e.g.tool.fawltydeps.code = ["bar.py", "baz.py"]
). (Also don't forget thefawltydeps_*
environment variables that exist between the config file and command-line in the configuration cascade...)The current behavior is to override/replace completely for all
Settings
members that are defined at each level. No effort is taken to more "smartly" integrate the values at one level (e.g. the config file) with values at another level (e.g. the command line).Quoting the relevant discussion on #321:
@Nour-Mws writes:
@jherland writes:
Tagging this as fairly low-priority for now, given that we do not yet have much external pressure to do anything about this.
The text was updated successfully, but these errors were encountered: