-
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
2681 s1 enhancements #2817
2681 s1 enhancements #2817
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #2817 +/- ##
===========================================
- Coverage 93.63% 93.58% -0.06%
===========================================
Files 266 268 +2
Lines 6083 6185 +102
Branches 513 526 +13
===========================================
+ Hits 5696 5788 +92
- Misses 294 305 +11
+ Partials 93 92 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 3 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
- add safety to custom validators where type exceptions could occur
- add logging - fix lint
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.
LGTM!
- update test file
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.
👍
…2681-s1-enhancements
@elipe17 approval here is pending your input on the test notes here, specifically: when AGE is invalid (i.e. DOB== |
@ADPennington that error arrises because of the exception handling in the new validator. If you would prefer to return a |
@@ -412,8 +412,8 @@ def dateDayIsValid(): | |||
def olderThan(min_age): | |||
"""Validate that value is larger than min_age.""" | |||
return make_validator( | |||
lambda value: date.today().year - int(str(value)[:4]) > min_age, | |||
lambda value: (f"{str(value)[:4]} must be less than or equal to {date.today().year - min_age} " | |||
lambda value: datetime.date.today().year - int(str(value)[:4]) > min_age, |
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.
just noting for reference that this validator is not needed.
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.
Summary of Changes
Note: The FIPS/Tribe code update already exists because of the relation in the database. Accessing those fields within the record has also been covered in #2805 by adding STT as a queryable field in the search indices.
Pull request closes #2681
How to Test
List the steps to test the PR
These steps are generic, please adjust as necessary.
Deliverables
More details on how deliverables herein are assessed included here.
Deliverable 1: Accepted Features
Checklist of ACs:
Deliverable 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):