Closed Bug 747057 Opened 12 years ago Closed 12 years ago

Nicer currency errors

Categories

(addons.mozilla.org Graveyard :: Code Quality, defect, P3)

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: andy+bugzilla, Assigned: andy+bugzilla)

References

Details

When a paypal transaction fails due to currency issues, we should bubble up a nice message. There's two primary errors. On sale we'll get:

 (559044): The receiver andy_1314044418_per@gmail.com does not accept payments in this Currency

We need to provide a string to the front end for in app and purchase pages that surfaces this message. Something like: "You tried to purchase in CAD but this app only accepts USD and YEN".

Then on refund we'll get an error like:

'currencyCode': 'USD', 'responseEnvelope.timestamp': '2012-04-18T18:05:22.133-07:00', 'responseEnvelope.correlationId': 'c031ce280e722', 'refundInfoList.refundInfo(1).receiver.amount': '0.30', 'refundInfoList.refundInfo(1).refundStatus': 'INSUFFICIENT_BALANCE',

That's because there isn't enough USD in receive (1) for that currency. This should be something like "We tried to refund 0.30 from account foo@bar.com, but there isn't enough balance in that account." This error will be sent in emails and logs to the relevant people.
Assignee: nobody → ashort
STR:
1. Have your default current set to EURO and set up preauth
2. Pick an app which doesn't support that currency- https://marketplace-dev.allizom.org/en-US/app/in-app-payment-tester/?src=search
3. Try to purchase the app.

expected behavior:
we show a proper error message informing about the currency issue OR gracefully fail and use USD.

actual behavior:
We show "Error communicating Paypal.Please try again later". Trying again will result in the same error.
Krupa is concerned about people setting up the wrong currency and then not being able to buy anything at all.  Currencies are still something we're working on getting right but I'm changing this to P2 to make her happy.  It doesn't block the launch or anything, just a "this is more important that the p3s" kind of thing.
More explicit error on purchase fail: 

https://github.com/mozilla/zamboni/commit/ef118626e4d1e7504771dd0fe3011f4ab9432261
Assignee: ashort → amckay
If it fails pre-approval, we retry without pre-approval in USD when purchasing:

https://github.com/mozilla/zamboni/commit/e0ec4f07ad022d17766ced713c750cb7382aa087
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.