PacktPublishing / Django-4-by-example

Django 4 by example (4th Edition) published by Packt
https://djangobyexample.com/
MIT License
799 stars 461 forks source link

Chapter 9 [500] POST http://localhost:8000/payment/webhook #36

Closed alexstelmakh closed 1 year ago

alexstelmakh commented 1 year ago

Hi everyone! I'm getting this kind of response

[500] POST http://localhost:8000/payment/webhook

no matter during the debug session or just when the development server is running. My webhook_view does not run therefore I cannot change the order status to 'paid'. Does someone know why this happens?

alexstelmakh commented 1 year ago

Solved! I did not paid attention to that trailing slash at the end of the stripe listen command.

Wrong !!!
stripe listen --forward-to localhost:8000/payment/webhook
Right !!!
stripe listen --forward-to localhost:8000/payment/webhook/