mirror of
https://github.com/varun-r-mallya/py-libp2p.git
synced 2026-02-12 16:10:57 +00:00
Refine Mplex.close and SwarmConn.close
Ensure `close` cleans up things and cancel the service finally.
This commit is contained in:
@ -69,9 +69,8 @@ async def raw_conn_factory(
|
||||
tcp_transport = TCP()
|
||||
listener = tcp_transport.create_listener(tcp_stream_handler)
|
||||
await listener.listen(LISTEN_MADDR, nursery)
|
||||
listening_maddr = listener.multiaddrs[0]
|
||||
listening_maddr = listener.get_addrs()[0]
|
||||
conn_0 = await tcp_transport.dial(listening_maddr)
|
||||
print("raw_conn_factory")
|
||||
yield conn_0, conn_1
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user