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

Process bulk upload fails if Region10Loader.make_contract() returns None #1594

toolness opened this Issue Oct 4, 2017 · 0 comments


None yet
1 participant

toolness commented Oct 4, 2017

The bulk upload processing code in data_capture/ calls Region10Loader.make_contract() (in contracts/loaders/ and expects it to always return a contract object or throw an exception. However, looking at the implementation of that function, there is an edge case where it actually returns None. This later causes an exception to be raised, when code further down the pipeline attempts to call update_normalized_labor_category on None.

I think we can fix this by having the edge case raise a ValueError or a ValidationError instead of returning None.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment