explicitly .close() task in http.request_many()

This commit is contained in:
jesopo 2020-01-06 17:04:30 +00:00
parent 08162f8505
commit 7478d62b77

View file

@ -258,6 +258,7 @@ def request_many(requests: typing.List[Request]) -> typing.Dict[str, Response]:
task = asyncio.wait(awaits, loop=loop, timeout=5)
loop.run_until_complete(task)
loop.close()
task.close()
return responses