Skip to content
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

Combining required=true with defaults #517

Open
mkarg opened this issue May 12, 2021 · 1 comment
Open

Combining required=true with defaults #517

mkarg opened this issue May 12, 2021 · 1 comment

Comments

@mkarg
Copy link
Collaborator

mkarg commented May 12, 2021

Currently required=true enforces the explicit provision of a parameter at the command line. In fact, it would be very useful, is a default would be considered, i. e. the error message requesting the missing parameter only pops up if the default (provided either by a static initializationg function or by a IDefaultProvider) actually is null. The idea behind this is that an essential parameter can be loaded by a default provider, but if that fails the user can override by explicitly provide the parameter.

@nbuesing
Copy link

this feature would be helpful when initializing a class through some environment variable loading and then wanting them provided on the command line, only if not pre-populated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants