Skip to content
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

Matching API crashes when no value passed in for birth date or last name #8

Open
gregmundy opened this issue Jun 11, 2019 · 1 comment

Comments

@gregmundy
Copy link
Contributor

Last name and date of births are two required fields; however, in the event that the end-user does not provide this data, the matching API should gracefully fail. In the event of no birth date, the API throws a SQLAlchemy error and does not generate a response. In the event of no last name, the algorithm will generate a brand new MCI entry with null as the last name.

@reginafcompton
Copy link
Contributor

@gregmundy and I discussed this. We concluded that:

If a user does not provide a last_name or date_of_birth, then by default the master-client-index should create a new user – without POSTing to the matching service. (Currently, we cannot imagine a DTA wanting a match-score threshold lower than 0.8.)

In other words, this query should never raise an error:

potential_matches = Session.query(individual_table).filter_by(
last_name=individual_args['last_name'],
date_of_birth=individual_args['date_of_birth']
)

However, it might be worthwhile to add exception handling, at this point – just in case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants