When AsyncClient is used several times with an async function that's sending an http request, the first time is successful, all other attempts are failing with RuntimeError exception and "Event loop is closed" error message.
To reproduce:
import httpx
if name == 'main':
client = httpx.AsyncClient()
async def home():
r = await client.get('https://www.example.com/')
return r
asyncio.run(home())
asyncio.run(home()) # => RuntimeError: Event loop is closed
asyncio.run(home()) # => RuntimeError: Event loop is closed
asyncio.run(home()) # => RuntimeError: Event loop is closed