fix: catch AssertionErrors

This commit is contained in:
Vlad Stan 2023-03-16 15:27:07 +02:00
parent 18196bf226
commit 9ce316debe
2 changed files with 91 additions and 6 deletions

View file

@ -110,7 +110,7 @@ async def handle_order_paid(order_id: str, merchant_pubkey: str):
merchant = await get_merchant_by_pubkey(merchant_pubkey)
assert merchant, f"Merchant cannot be found for order {order_id}"
# lock
# todo: lock
success, message = await update_products_for_order(merchant, order)
await notify_client_of_order_status(order, merchant, success, message)
except Exception as ex: