Steffo99 / greed

Customizable, multilanguage Telegram shop bot with Payments support
GNU Affero General Public License v3.0
534 stars 262 forks source link

fix-2 sqlalchemy exception #115

Closed valentino-sm closed 3 years ago

valentino-sm commented 3 years ago

I'm not sure a proper way fix but the payment works.

Exception was: (raised as a result of Query-invoked autoflush; consider using a session.no_autoflush block if this flush is occurring prematurely) (sqlite3.IntegrityError) NOT NULL constraint failed: orderitems.order_id [SQL: INSERT INTO orderitems (product_id, order_id) VALUES (?, ?)] [parameters: (3, None)] (Background on this error at: http://sqlalche.me/e/14/gkpj) After the successful payment. Sorry again for the last commit 730fa96e56a09d681624a93a56f428d92b0afc27

Steffo99 commented 3 years ago

My bad, I should have tested it before merging :sweat_smile: