Compare commits
No commits in common. "8810679fd8ea2dd6e63b09bf9a4b9af5c2d0fdd2" and "e6f702a6b405f1dae0ce719177c6f7bf5b636ad8" have entirely different histories.
8810679fd8
...
e6f702a6b4
@ -81,12 +81,10 @@ class Application(BaseApplication):
|
||||
async def task_runner(self):
|
||||
while True:
|
||||
task = await self.tasks.get()
|
||||
self.db.begin()
|
||||
try:
|
||||
await task
|
||||
except Exception as ex:
|
||||
print(ex)
|
||||
self.db.commit()
|
||||
|
||||
async def prepare_database(self,app):
|
||||
self.db.query("PRAGMA journal_mode=WAL")
|
||||
|
@ -203,7 +203,9 @@ class RPCView(BaseView):
|
||||
if msg.type == web.WSMsgType.TEXT:
|
||||
try:
|
||||
async with Profiler():
|
||||
self.app.db.begin()
|
||||
await rpc(msg.json())
|
||||
self.app.db.commit()
|
||||
except Exception as ex:
|
||||
print(ex, flush=True)
|
||||
await self.services.socket.delete(ws)
|
||||
|
Loading…
Reference in New Issue
Block a user