diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-11-24 17:23:18 +0100 |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-11-24 17:23:18 +0100 |
commit | f792f2d3b3b75382bdf2f6b2b5a2fbfa3e0728a7 (patch) | |
tree | c8b9bbb4d2c8d282b2e66ae4b3d9050b4e79eb8f | |
parent | d443ac2f43311099e3627a722438f5721d1b29b4 (diff) | |
download | aioeventlet-f792f2d3b3b75382bdf2f6b2b5a2fbfa3e0728a7.tar.gz |
Rename the EventLoop class to EventletEventLoop, and rename the EventLoopPolicy
class to EventletEventLoopPolicy
-rw-r--r-- | aiogreen.py | 16 | ||||
-rw-r--r-- | doc/changelog.rst | 7 | ||||
-rw-r--r-- | doc/conf.py | 4 | ||||
-rw-r--r-- | setup.py | 2 | ||||
-rw-r--r-- | tests/__init__.py | 2 |
5 files changed, 19 insertions, 12 deletions
diff --git a/aiogreen.py b/aiogreen.py index 012bab3..08c8d46 100644 --- a/aiogreen.py +++ b/aiogreen.py @@ -189,7 +189,7 @@ class _Selector(asyncio.selectors._BaseSelectorImpl): self._event = None -class EventLoop(asyncio.SelectorEventLoop): +class EventletEventLoop(asyncio.SelectorEventLoop): def __init__(self): self._greenthread = None @@ -199,7 +199,7 @@ class EventLoop(asyncio.SelectorEventLoop): selector = _Selector(self, self._hub) - super(EventLoop, self).__init__(selector=selector) + super(EventletEventLoop, self).__init__(selector=selector) # Force a call to set_debug() to set hub.debug_blocking self.set_debug(self.get_debug()) @@ -208,7 +208,7 @@ class EventLoop(asyncio.SelectorEventLoop): self._default_executor = _TpoolExecutor(self) def call_soon(self, callback, *args): - handle = super(EventLoop, self).call_soon(callback, *args) + handle = super(EventletEventLoop, self).call_soon(callback, *args) if self._selector is not None and self._selector._event: # selector.select() is running: write into the self-pipe to wake up # the selector @@ -216,7 +216,7 @@ class EventLoop(asyncio.SelectorEventLoop): return handle def call_at(self, when, callback, *args): - handle = super(EventLoop, self).call_at(when, callback, *args) + handle = super(EventletEventLoop, self).call_at(when, callback, *args) if self._selector is not None and self._selector._event: # selector.select() is running: write into the self-pipe to wake up # the selector @@ -224,7 +224,7 @@ class EventLoop(asyncio.SelectorEventLoop): return handle def set_debug(self, debug): - super(EventLoop, self).set_debug(debug) + super(EventletEventLoop, self).set_debug(debug) self._hub.debug_exceptions = debug @@ -245,7 +245,7 @@ class EventLoop(asyncio.SelectorEventLoop): def run_forever(self): self._greenthread = eventlet.getcurrent() try: - super(EventLoop, self).run_forever() + super(EventletEventLoop, self).run_forever() finally: if self._hub.debug_blocking: # eventlet event loop is still running: cancel the current @@ -257,8 +257,8 @@ class EventLoop(asyncio.SelectorEventLoop): return self._hub.clock() -class EventLoopPolicy(asyncio.DefaultEventLoopPolicy): - _loop_factory = EventLoop +class EventletEventLoopPolicy(asyncio.DefaultEventLoopPolicy): + _loop_factory = EventletEventLoop def wrap_greenthread(gt, loop=None): diff --git a/doc/changelog.rst b/doc/changelog.rst index 87f368e..14a4e6f 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -1,6 +1,13 @@ Changelog ========= +Version 0.4 +----------- + +* Rename the :class:`EventLoop` class to :class:`EventletEventLoop`, + and rename the :class:`EventLoopPolicy` class to + :class:`EventletEventLoopPolicy` + 2014-10-23: version 0.3 ----------------------- diff --git a/doc/conf.py b/doc/conf.py index 752f97b..a5bf6dc 100644 --- a/doc/conf.py +++ b/doc/conf.py @@ -51,9 +51,9 @@ copyright = u'2014, Victor Stinner' # built documents. # # The short X.Y version. -version = '0.3' +version = '0.4' # The full version, including alpha/beta/rc tags. -release = '0.3' +release = '0.4' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. @@ -44,7 +44,7 @@ with open("README") as fp: install_options = { "name": "aiogreen", - "version": "0.3", + "version": "0.4", "license": "Apache License 2.0", "author": 'Victor Stinner', "author_email": 'victor.stinner@gmail.com', diff --git a/tests/__init__.py b/tests/__init__.py index 2686fbc..2ed0eff 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -15,7 +15,7 @@ except ImportError: class TestCase(unittest.TestCase): def setUp(self): - policy = aiogreen.EventLoopPolicy() + policy = aiogreen.EventletEventLoopPolicy() asyncio.set_event_loop_policy(policy) self.addCleanup(asyncio.set_event_loop_policy, None) |