-
Notifications
You must be signed in to change notification settings - Fork 4
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
Deprecate Validators #3383
base: develop
Are you sure you want to change the base?
Deprecate Validators #3383
Conversation
- deprecated cat4 validators, add deprecation warning message - added migration
- Updated row schema to collect the deprecated flag from the validators and create the parser error with it - Updated error generators to use deprecated flag in util.py - update cat3 validators to leverage deprecated flag - add inline and decorator versions of validator deprecators - removed prints from reparse
- Add tests for deprecation functions
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #3383 +/- ##
===========================================
+ Coverage 91.48% 91.51% +0.02%
===========================================
Files 299 300 +1
Lines 8595 8624 +29
Branches 636 636
===========================================
+ Hits 7863 7892 +29
Misses 615 615
Partials 117 117
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Sentry.
|
return wrapper | ||
|
||
|
||
def deprecate_call(validator): |
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 realized after OH 12/20/24 why this had to be a function/decorator as opposed to passing deprecated=True
in the kwargs of the validators. The reason is because we need to modify the return value of the validator function where as the kwargs are intended to manipulate the input of the validator function. I can't see a way to get around that for the time being, but open to other suggestions! Or, if im missing something and it can be done with kwargs i'd love to pair on it!
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.
We also will not be able to deduce the validators true name because it has already been invoked and returns the function named validator
from the make_validator
function.
- Updated test and removed print
Summary of Changes
Pull request closes Deprecate Cat 4 validation checks for case closure #3342
How to Test
deprecate_validator
decorator anddeprecate_call
function. Validators encapsulated in these functions should not add errors to the error report or effect case aggregates/total aggregatesDeliverables
More details on how deliverables herein are assessed included here.
Deliverable 1: Accepted Features
Checklist of ACs:
__validate_case_closure_employment()
deprecated__validate_case_closure_ftl()
deprecated__validate_t5_atd_and_ssi()
deprecatedDeliverable 2: Tested Code
CodeCov Report
comment in PR)CodeCov Report
comment in PR)Deliverable 3: Properly Styled Code
Deliverable 4: Accessible
iamjolly
andttran-hub
using Accessibility Insights reveal any errors introduced in this PR?Deliverable 5: Deployed
Deliverable 6: Documented
Deliverable 7: Secure
Deliverable 8: User Research
Research product(s) clearly articulate(s):