-
Notifications
You must be signed in to change notification settings - Fork 21
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
Remove ct validation when active validation is disabled (#269) #271
Merged
Conversation
This file contains 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
* Do not validate command table in as_dict() when active validation is off
* is_valid() can be used to validate the command table
4 tasks
markheik
changed the title
Markush/remove ct validation when disabled
Remove ct validation when active validation is disabled (#269)
Oct 20, 2023
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #271 +/- ##
=======================================
Coverage 99.60% 99.61%
=======================================
Files 40 40
Lines 2552 2567 +15
=======================================
+ Hits 2542 2557 +15
Misses 10 10
☔ View full report in Codecov by Sentry. |
markheik
changed the title
Remove ct validation when active validation is disabled (#269)
Draft: Remove ct validation when active validation is disabled (#269)
Oct 23, 2023
markheik
force-pushed
the
markush/remove_ct_validation_when_disabled
branch
from
November 2, 2023 12:01
08894d5
to
8207d5e
Compare
@@ -442,8 +447,13 @@ | |||
) | |||
|
|||
def _table_entry(self) -> ListEntry: | |||
schema = copy.deepcopy(self._ct_schema["definitions"]["table"]) | |||
index_schema = schema["items"]["properties"].pop("index") |
Check failure
Code scanning / CodeQL
Modification of parameter with default Error
This expression mutates a .
default value
Error loading related location
Loading
markheik
changed the title
Draft: Remove ct validation when active validation is disabled (#269)
Remove ct validation when active validation is disabled (#269)
Nov 2, 2023
* Remove unnecessary deepcopy of table index schemas to improve performance
markheik
force-pushed
the
markush/remove_ct_validation_when_disabled
branch
from
November 2, 2023 12:16
5da96b4
to
c610f09
Compare
tobiasah
approved these changes
Nov 2, 2023
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.
Description:
To improve
CommandTable
creation and usage, do not validate it duringas_dict()
.Introduces
is_valid()
method compensate for optional validation.Removed unnecessary
deepcopy
of schemas for speed improvementThe following script is 10x faster than with copying:
Fixes issue: #269
Checklist: