cron: commit roulette txn early for long tasks.

master
Snakes 2022-09-29 13:45:13 -04:00
parent 6b0c734254
commit e52fc4eb9e
1 changed files with 3 additions and 0 deletions

View File

@ -202,6 +202,9 @@ def spin_roulette_wheel():
game.active = False game.active = False
g.db.add(game) g.db.add(game)
# Commit early when dirty because of long-running tasks after roulette
g.db.commit()
def determine_roulette_winners(number, bets): def determine_roulette_winners(number, bets):
winners = [] winners = []