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

missing configuration file fails silently #3

Closed
omry opened this issue Sep 1, 2018 · 5 comments
Closed

missing configuration file fails silently #3

omry opened this issue Sep 1, 2018 · 5 comments

Comments

@omry
Copy link

omry commented Sep 1, 2018

it would be good if at least an warning was printed to tell the user that the configuration file was not found.
failing silently is a sure way to confuse the users, especially in the presence of all the default options.

def __read_file(self, path):

@andrasmaroy
Copy link
Owner

I agree with the warning part, but I didn't want to introduce logging just for this case. It probably should at some point though.

As for failing silently it is consistent with the other options, if you don't use a command line parameter that won't make it blow up, same with environment variables, etc.

@omry
Copy link
Author

omry commented Sep 2, 2018

hence warning and not an exception :)
there is a difference between specifying an incorrect file name and not specifying a file at all.

@andrasmaroy
Copy link
Owner

Yes, totally makes sense, I'll add a warning for IOErrors caught during opening files.

@andrasmaroy
Copy link
Owner

I've added a warning for this, it will be included in the next release.

@omry
Copy link
Author

omry commented Sep 4, 2018

thanks.
I started my own config lib project, omegaconf.
feedback welcome.

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