import asyncio class Ticker: def __init__(self, pair): self.pair = pair self.price = None self.sell = None self.buy = None self.volume = None self.ts = None self._event = asyncio.Event() async def wait(self): await self._event.wait()