Await tasks before stopping the session

This commit is contained in:
Dan 2018-06-17 18:34:10 +02:00
parent 2b0746a140
commit 6da15b266d

View File

@ -186,10 +186,10 @@ class Session:
self.connection.close()
if self.recv_task:
await self.recv_task
self.recv_queue.put_nowait(None)
if self.net_worker_task:
await self.net_worker_task
for i in self.results.values():