Skip to content
This repository was archived by the owner on Jan 23, 2024. It is now read-only.

Fix CA regex #332

Closed
lippytak opened this issue Dec 17, 2015 · 4 comments
Closed

Fix CA regex #332

lippytak opened this issue Dec 17, 2015 · 4 comments
Assignees
Labels

Comments

@lippytak
Copy link
Contributor

So right now every CA user who DOES NOT have a positive SNAP AND Cash balance is getting the having_trouble_try_again_message response:
screen shot 2015-12-17 at 12 06 02 pm

Here are our 50 most recent outbound texts on our main CA number:
screen shot 2015-12-17 at 12 03 35 pm

The reason is that Twilio (or the provider) changed their transcription content to return 'zero dollars' instead of '$0.00' and our regex isn't catching these. Because in CA we're always looking for 2 matches (elsif regex_matches.count > 1), then if either balance transcription returns 'zero dollars' we just return having_trouble_try_again_message.

Example new transcription:

Balance is $243.28. Your cash account balance is zero dollars.
https://www.twilio.com/user/account/voice/log/transcriptions/TR318ef554ff99dcbe8b7191504685803c

SO, I think if we just start picking up 'zero dollars' in our CA handler regex then we should be all good.

@daguar
Copy link
Contributor

daguar commented Dec 17, 2015

👍 Moving to current sprint

@lippytak
Copy link
Contributor Author

Two additional things:

  • Since the issue is with the underlying Twilio transcription this is probably affecting all states, so we should update all handlers.
  • Looks like this has been happening since late October, so we should brainstorm how to setup monitoring that catches similar cases in the future.

@daguar
Copy link
Contributor

daguar commented Dec 17, 2015

😭

@daguar
Copy link
Contributor

daguar commented Dec 18, 2015

Closed by #333 — adding this to other states is #334 and expanding this to values beyond zero is #335

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

No branches or pull requests

2 participants