Rafael
08/17/2024, 3:06 PMimport asyncio
from httpx import AsyncClient
from prefect import flow, task
@task
async def fetch(client: AsyncClient):
await client.get('<http://example.com>')
@flow
async def main():
async with AsyncClient() as client:
await fetch(client)
if __name__ == "__main__":
asyncio.run(main())
Flow run encountered an exception. RuntimeError: Event loop is closedNate
08/18/2024, 11:45 PM