def METHOD_NAME(self, waiters):
    # Wake up the next waiter (if any) that isn't cancelled.
    while waiters:
        waiter = waiters.popleft()
        if not waiter.done():
            waiter.set_result(None)
            break