error catching
This commit is contained in:
@@ -53,9 +53,12 @@ from rowers.models import Rower,PaidPlan, CoachingGroup
|
||||
from rowers.utils import ProcessorCustomerError
|
||||
|
||||
def webhook(request):
|
||||
webhook_notification = gateway.webhook_notification.parse(
|
||||
str(request.POST['bt_signature']),
|
||||
request.POST['bt_payload'])
|
||||
try:
|
||||
webhook_notification = gateway.webhook_notification.parse(
|
||||
str(request.POST['bt_signature']),
|
||||
request.POST['bt_payload'])
|
||||
except:
|
||||
print(sys.exc_info())
|
||||
|
||||
# Example values for webhook notification properties
|
||||
print(webhook_notification.kind) # "subscription_went_past_due"
|
||||
|
||||
Reference in New Issue
Block a user