nycmeshnet / meshdb

A convenient, stable, and sane database for tracking Members and Nodes for use with robots and humans
https://db.nycmesh.net
MIT License
8 stars 13 forks source link

Phone number handling overhaul #450

Closed Andrew-Dickinson closed 1 month ago

Andrew-Dickinson commented 1 month ago

Overhauls how we handle phone numbers, promoting them to first class identifiers of individuals. We now use them to de-duplicate at join form submission time, as well as at import script time.

We also now validate phone numbers at all ingress points, rejecting API calls that submit invalid numbers. We also normalize to a standard format, regardless of how the client provides the number, so that string comparisons are sufficient for uniqueness determination.

Also overhauls join form de-duplication, including name change detection, which triggers a notification on slack for an admin to resolve

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 96.55172% with 3 lines in your changes missing coverage. Please review.

Project coverage is 92.76%. Comparing base (e43b5dc) to head (b3034aa). Report is 1 commits behind head on main.

Files Patch % Lines
src/meshapi/util/admin_notifications.py 96.96% 1 Missing :warning:
src/meshapi/validation.py 93.33% 1 Missing :warning:
src/meshapi/views/forms.py 96.77% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #450 +/- ## ========================================== + Coverage 92.65% 92.76% +0.11% ========================================== Files 61 62 +1 Lines 2232 2308 +76 ========================================== + Hits 2068 2141 +73 - Misses 164 167 +3 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

Andrew-Dickinson commented 1 month ago

Closes #374

Andrew-Dickinson commented 1 month ago

Whoops I left auto-merge on 😓