From ae0e1bfaefa5ad7747ca248f96dd0134867cf4a6 Mon Sep 17 00:00:00 2001 From: Lex Berezhny Date: Mon, 15 Oct 2018 08:56:23 -0400 Subject: [PATCH] support python 3.6 --- torba/baseheader.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/torba/baseheader.py b/torba/baseheader.py index 5526c3fb6..dfe60f900 100644 --- a/torba/baseheader.py +++ b/torba/baseheader.py @@ -95,7 +95,9 @@ class BaseHeaders: async def connect(self, start: int, headers: bytes) -> int: added = 0 bail = False - loop = asyncio.get_running_loop() + # TODO: switch to get_running_loop() after depricating python 3.6 support + #loop = asyncio.get_running_loop() + loop = asyncio.get_event_loop() async with self._header_connect_lock: for height, chunk in self._iterate_chunks(start, headers): try: