MCPcopy Create free account
hub / github.com/bslatkin/effectivepython / handle_async_connection

Function handle_async_connection

example_code/item_076.py:436–441  ·  view source on GitHub ↗
(reader, writer)

Source from the content-addressed store, hash-verified

434import asyncio
435
436async def handle_async_connection(reader, writer):
437 session = AsyncServerSession(reader, writer)
438 try:
439 await session.loop()
440 except EOFError:
441 pass
442
443async def run_async_server(address):
444 server = await asyncio.start_server(

Callers

nothing calls this directly

Calls 2

loopMethod · 0.95
AsyncServerSessionClass · 0.85

Tested by

no test coverage detected