azavea / pfb-network-connectivity

PFB Bicycle Network Connectivity
Other
40 stars 10 forks source link

Raise errors when population is zero #913

Closed KlaasH closed 1 year ago

KlaasH commented 1 year ago

Overview

This adds two checks for the situation that caused Milton Keynes to fail during final import and bring the API down with it. The root of the problem was that there was no population in the imported blocks within the neighborhood boundary, but the way that error manifested was not helpful. It ran the whole analysis and imported the broken score results, then failed because the blank population value caused an error on the database level for any query that tried to load the record.

The two new pieces of error-checking:

Resolves #911

Notes

This is based on the branch for PR #912 because it needs those fixes, but I didn't want to make it all into one even-bigger PR.

Testing Instructions

Checklist