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:
@ -1,7 +1,4 @@
|
||||
from abc import (
|
||||
ABC,
|
||||
abstractmethod,
|
||||
)
|
||||
from abc import ABC, abstractmethod
|
||||
from typing import TYPE_CHECKING
|
||||
|
||||
from multiaddr import Multiaddr
|
||||
@ -15,44 +12,43 @@ if TYPE_CHECKING:
|
||||
|
||||
|
||||
class INotifee(ABC):
|
||||
|
||||
@abstractmethod
|
||||
async def opened_stream(self, network: 'INetwork', stream: INetStream) -> None:
|
||||
async def opened_stream(self, network: "INetwork", stream: INetStream) -> None:
|
||||
"""
|
||||
:param network: network the stream was opened on
|
||||
:param stream: stream that was opened
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def closed_stream(self, network: 'INetwork', stream: INetStream) -> None:
|
||||
async def closed_stream(self, network: "INetwork", stream: INetStream) -> None:
|
||||
"""
|
||||
:param network: network the stream was closed on
|
||||
:param stream: stream that was closed
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def connected(self, network: 'INetwork', conn: IMuxedConn) -> None:
|
||||
async def connected(self, network: "INetwork", conn: IMuxedConn) -> None:
|
||||
"""
|
||||
:param network: network the connection was opened on
|
||||
:param conn: connection that was opened
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def disconnected(self, network: 'INetwork', conn: IMuxedConn) -> None:
|
||||
async def disconnected(self, network: "INetwork", conn: IMuxedConn) -> None:
|
||||
"""
|
||||
:param network: network the connection was closed on
|
||||
:param conn: connection that was closed
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def listen(self, network: 'INetwork', multiaddr: Multiaddr) -> None:
|
||||
async def listen(self, network: "INetwork", multiaddr: Multiaddr) -> None:
|
||||
"""
|
||||
:param network: network the listener is listening on
|
||||
:param multiaddr: multiaddress listener is listening on
|
||||
"""
|
||||
|
||||
@abstractmethod
|
||||
async def listen_close(self, network: 'INetwork', multiaddr: Multiaddr) -> None:
|
||||
async def listen_close(self, network: "INetwork", multiaddr: Multiaddr) -> None:
|
||||
"""
|
||||
:param network: network the connection was opened on
|
||||
:param multiaddr: multiaddress listener is no longer listening on
|
||||
|
||||
Reference in New Issue
Block a user