-
Notifications
You must be signed in to change notification settings - Fork 5
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 a config mechanism #126
Conversation
Let me get into this in one of the coming days. This is about fixing issue #74 , right? |
Yes, that's right |
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 can't immediately grasp the idea behind the _Validate class and the validate_nested function.
They are my implementation to do type validation without adding additional dependencies. As I mentioned in the PR intro, for simple flat data structures, it should work. It's somewhat future proof. Basically it prevents the user from providing incorrect data types in the config. |
Allright, aside from a few adjustments - removing sep and appropriate default values - we can move forward after fixing the build problem: |
The unit tests may pass since the global variables are still used. |
Features
None
because I didn't know what would be most appropriate.list
(including multi-dimensional),dict
as long as they are flat will validate correctly.How to use?
@HannoSpreeuw, I wonder if you have any preference how to use the config object. Typically I would adjust the code so that where relevant you pass a config object.