Open hanstakeshi opened 6 years ago
Have you checked the event and EventProcessingException logs / entries to see where "sli_*" is coming from?
Hello blueyed, thank you for the answer. i've been checked that error, and literally it show the same information.
We've already an account in Stripe for international payments using pinax-stripe(pinax-stripe==4.3.0), but it doesn't have any error in the webhook called invoice.payment_succeeded... (this Stripe account was created four years ago, and it's using webhook's version 2014, that's the unique diferente between this new Stripe account and the old Stripe account)
Greetings.
The issue is due to the new stripe api version. Edit pinax/stripe/actions/invoices.py
line 167 from item["id"]
to item["subscription"]
.
Issue Summary
We are getting a bit of trouble with the webhook called "invoice.payment_succeeded". All the subscriptions are created in the dashboard with the format "sub_DCXg.....", but the package make internal an id subscription with the format "sli_ABcDX..." (we dont know why).
In the function sync_invoice_items (pinax/stripe/actions/invoices.py), it is doing a comparation with invoice.subscription.stripe_id and item["id"] but they are different:
so in the else, it try to retrieve the subscription with the fields customer and the item id but it doesnt exist in my dashboard stripe panel raising an error: