From 580c5a4712fd5d825175fe93db16f1e3d972b79b Mon Sep 17 00:00:00 2001 From: Brian Warner Date: Mon, 3 Apr 2017 23:50:57 -0700 Subject: [PATCH] remove unused channel_monitor.py --- src/wormhole/channel_monitor.py | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 src/wormhole/channel_monitor.py diff --git a/src/wormhole/channel_monitor.py b/src/wormhole/channel_monitor.py deleted file mode 100644 index f5f4c50..0000000 --- a/src/wormhole/channel_monitor.py +++ /dev/null @@ -1,16 +0,0 @@ -from __future__ import print_function, unicode_literals -import sys -from weakref import ref - -class ChannelMonitor: - def __init__(self): - self._open_channels = set() - def add(self, w): - wr = ref(w, self._lost) - self._open_channels.add(wr) - def _lost(self, wr): - print("Error: a Wormhole instance was not closed", file=sys.stderr) - def close(self, w): - self._open_channels.discard(ref(w)) - -monitor = ChannelMonitor() # singleton