diff --git a/eventlet/hubs/libevent.py b/eventlet/hubs/libevent.py index bab7f90..c6377c2 100644 --- a/eventlet/hubs/libevent.py +++ b/eventlet/hubs/libevent.py @@ -5,10 +5,10 @@ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: -# +# # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. -# +# # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE @@ -24,9 +24,6 @@ import time from eventlet.hubs import hub -# XXX for debugging only -#raise ImportError() - try: # use rel if available import rel @@ -39,7 +36,7 @@ except ImportError: import event -class Hub(hub.BaseHub): +class Hub(hub.BaseHub): def __init__(self, clock=time.time): super(Hub, self).__init__(clock) self.interrupted = False @@ -77,7 +74,7 @@ class Hub(hub.BaseHub): def signal_received(self, signal): # can't do more than set this flag here because the pyevent callback - # mechanism swallows exceptions raised here, so we have to raise in + # mechanism swallows exceptions raised here, so we have to raise in # the 'main' greenlet (in wait()) to kill the program self.interrupted = True event.abort() @@ -103,7 +100,7 @@ class Hub(hub.BaseHub): # raise any signals that deserve raising if self.interrupted: self.interrupted = False - raise KeyboardInterrupt() + raise KeyboardInterrupt() def add_timer(self, timer): # store the pyevent timer object so that we can cancel later