Repository navigation
add settings validation - #797
Merged
Merged
Conversation
Codecov Report
@@ Coverage Diff @@
## master #797 +/- ##
==========================================
+ Coverage 98.22% 98.24% +0.02%
==========================================
Files 231 231
Lines 2533 2569 +36
==========================================
+ Hits 2488 2524 +36
Misses 45 45
Continue to review full report at Codecov.
|
noviluni
commented
Sep 29, 2020
|
|
||
| def _check_require_part(provided_list): | ||
| """Returns `True` if the provided list of parts is valid""" | ||
| return not set(provided_list) - {'day', 'month', 'year'} |
Contributor
Author
There was a problem hiding this comment.
should I check the length to avoid duplicated values?
Contributor
There was a problem hiding this comment.
I think that would be great.
noviluni
force-pushed
the
add_settings_validation
branch
from
September 29, 2020 06:38
8f71476 to
aa916b5
Compare
Gallaecio
reviewed
Sep 30, 2020
|
|
||
| def _check_require_part(provided_list): | ||
| """Returns `True` if the provided list of parts is valid""" | ||
| return not set(provided_list) - {'day', 'month', 'year'} |
Contributor
There was a problem hiding this comment.
I think that would be great.
Contributor
Author
|
Hi @Gallaecio , I addressed all of your feedback, could you review it again? Thank you! |
Contributor
Author
|
Note that this new behaviour will be documented in this PR: #722 |
Gallaecio
approved these changes
Oct 26, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Adding settings validation in one single place. In that way, we can raise an error if there is misconfigurations and we ensure that the submitted settings are valid.
for: #796
It's not fully finished, as we need a way to get a list of the existing parsers.I would prefer to get the "existing parsers" from another place (#798), but I think this can be refactored in the future.