import asyncio


async def event_wait(evt, timeout):
    """Helper method to add a timeout to an asyncio wait"""
    try:
        await asyncio.wait_for(evt.wait(), timeout)
    except asyncio.TimeoutError:
        pass
    return evt.is_set()