politics-rewired / Spoke

Politics Rewired's fork of Spoke
GNU General Public License v3.0
35 stars 16 forks source link

Error from improperly formatted zip-code is not surfaced to user #439

Open bchrobot opened 4 years ago

bchrobot commented 4 years ago

Describe the bug

An improperly formatted zip code (ex O4551 -- note the O instead of a zero) throws an unhandled error. This causes the contact upload job to fail silently.

To Reproduce Steps to reproduce the behavior:

  1. Create contact list using zip code O4551
  2. Upload the list
  3. On the client, see that the job does not fail and no error is displayed to the user
  4. On the server, see an unhandled promise rejection error in the logs

Expected behavior

An invalid zip code should cause the job to fail to with an error message. This error message should be displayed on the web client.

bchrobot commented 4 years ago

02280/ and 03471- also slipped through without throwing an error