mirror of
https://github.com/varun-r-mallya/py-libp2p.git
synced 2025-12-31 20:36:24 +00:00
Run black over repo
This commit is contained in:
@ -40,7 +40,8 @@ class MplexStream(IMuxedStream):
|
||||
:return: number of bytes written
|
||||
"""
|
||||
return await self.mplex_conn.send_message(
|
||||
get_flag(self.initiator, "MESSAGE"), data, self.stream_id)
|
||||
get_flag(self.initiator, "MESSAGE"), data, self.stream_id
|
||||
)
|
||||
|
||||
async def close(self):
|
||||
"""
|
||||
@ -50,7 +51,9 @@ class MplexStream(IMuxedStream):
|
||||
"""
|
||||
# TODO error handling with timeout
|
||||
# TODO understand better how mutexes are used from go repo
|
||||
await self.mplex_conn.send_message(get_flag(self.initiator, "CLOSE"), None, self.stream_id)
|
||||
await self.mplex_conn.send_message(
|
||||
get_flag(self.initiator, "CLOSE"), None, self.stream_id
|
||||
)
|
||||
|
||||
remote_lock = ""
|
||||
async with self.stream_lock:
|
||||
@ -79,7 +82,8 @@ class MplexStream(IMuxedStream):
|
||||
|
||||
if not self.remote_closed:
|
||||
await self.mplex_conn.send_message(
|
||||
get_flag(self.initiator, "RESET"), None, self.stream_id)
|
||||
get_flag(self.initiator, "RESET"), None, self.stream_id
|
||||
)
|
||||
|
||||
self.local_closed = True
|
||||
self.remote_closed = True
|
||||
|
||||
Reference in New Issue
Block a user