diff options
| author | 2019-07-08 14:41:12 +0100 | |
|---|---|---|
| committer | 2019-07-08 14:41:12 +0100 | |
| commit | 469c7256750ce4d508737fcb1031895b2edf60e5 (patch) | |
| tree | 797490b10403039a6d002e66f51964811f29995f /src/utils/http.py | |
| parent | close event loop when we're done with it (request_many()) (diff) | |
| signature | ||
tell asyncio.gather which loop to use
Diffstat (limited to 'src/utils/http.py')
| -rw-r--r-- | src/utils/http.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/http.py b/src/utils/http.py index 88edeb46..e6ed9b24 100644 --- a/src/utils/http.py +++ b/src/utils/http.py @@ -131,7 +131,7 @@ def request_many(urls: typing.List[str]) -> typing.Dict[str, Response]: awaits = [] for url in urls: awaits.append(_request(url)) - task = asyncio.gather(*awaits, return_exceptions=True) + task = asyncio.gather(*awaits, return_exceptions=True, loop=loop) loop.run_until_complete(task) loop.close() |
