Refine Mplex.close and SwarmConn.close

Ensure `close` cleans up things and cancel the service finally.
This commit is contained in:
mhchia
2019-12-17 15:50:55 +08:00
parent d847e78a83
commit fb0519129d
13 changed files with 71 additions and 51 deletions

View File

@ -58,11 +58,11 @@ class TopicValidator(NamedTuple):
# TODO: Add interface for Pubsub
class BasePubsub(ABC):
class IPubsub(ABC):
pass
class Pubsub(BasePubsub, Service):
class Pubsub(IPubsub, Service):
host: IHost