Skip to content
Snippets Groups Projects
Commit 51cf0093 authored by ale's avatar ale
Browse files

yield after a db locking error

parent bfca6f25
Branches
No related tags found
No related merge requests found
......@@ -163,6 +163,7 @@ def readonly_transaction(db):
with transaction(db) as session:
yield session
except sqlalchemy.exc.OperationalError:
time.sleep(0.01)
continue
break
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment