👌 Improve reduce_need for schema validation#1633
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1633 +/- ##
==========================================
+ Coverage 86.87% 88.59% +1.71%
==========================================
Files 56 70 +14
Lines 6532 9955 +3423
==========================================
+ Hits 5675 8820 +3145
- Misses 857 1135 +278
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
ccb3ce0 to
c94fefd
Compare
Currently reduce_need depends on the schema to determine whether core fields should be added to the to-be-validated need. To run unevaluatedProperties validations. This is a performance issue, as the need reduction has to run for all need-schema combinations.
- Removed unnecessary checks for schema properties when processing link fields. - Updated logic to retain only non-empty link fields in the reduced need.
…nevaluated properties; update related tests
…es and empty fields
129490f to
c506d26
Compare
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.
The schema validation testing was lacking corner cases with regards to
unevaluatedProperties.This is now added, including fixes for default handling.
The docstring of
reduce_needwas expanded with the new rules.unevaluated_properties_test.csv