async def to_async_iter(iter: Iterator[_T]) -> AsyncIterator[_T]:
    """Convert a synchronous iterator to an asynchronous one."""
    for event in iter:
        yield event
Convert a synchronous iterator to an asynchronous one.
tests/lib/streaming/helpers.py