Add missing ensure_future
This commit is contained in:
parent
d18c756acd
commit
2076d9efff
|
|
@ -34,7 +34,7 @@ class Refresher:
|
||||||
async def refresh(self):
|
async def refresh(self):
|
||||||
while self._running:
|
while self._running:
|
||||||
with self.sessionmaker as session:
|
with self.sessionmaker as session:
|
||||||
self._wait_fut = asyncio.sleep(self._wait_time(session))
|
self._wait_fut = asyncio.ensure_future(asyncio.sleep(self._wait_time(session)))
|
||||||
try:
|
try:
|
||||||
await self._wait_fut
|
await self._wait_fut
|
||||||
except asyncio.CancelledError:
|
except asyncio.CancelledError:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue