Skip to content

Commit 7a7978e

Browse files
committed
1.3.2+wmc: trio-asyncio requires asyncio.get_event_loop().
The old code would use `get_running_loop()` preferentially if available, which results in a "No running loop" error, even if `trio-asyncio` has an open loop. Specifically, this is noted in an existing `trio-asyncio` issue: python-trio/trio-asyncio#83 It may be possible to use `aioredis==1.3.1` and just ensure it is imported _after_ `trio-asyncio`, in which case the `trio-asyncio` monkeypatching should work.
1 parent 8a20760 commit 7a7978e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

aioredis/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
)
2929

3030

31-
__version__ = '1.3.1'
31+
__version__ = '1.3.2+wmc'
3232

3333
__all__ = [
3434
# Factories

aioredis/util.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,4 +239,4 @@ def _cleanup(self, task):
239239
self._close_done.set()
240240

241241

242-
get_event_loop = getattr(asyncio, 'get_running_loop', asyncio.get_event_loop)
242+
get_event_loop = asyncio.get_event_loop

0 commit comments

Comments
 (0)