summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2016-02-22 17:23:39 +0100
committerVictor Stinner <victor.stinner@gmail.com>2016-02-22 17:23:39 +0100
commit817243e0bf6fc54487c2b10edcc8366dea100816 (patch)
tree778a369ac3164b06ccfe834108055973b4461a32
parentffac113995247122fb62ceb172ceb8621dbfc65c (diff)
downloadaioeventlet-817243e0bf6fc54487c2b10edcc8366dea100816.tar.gz
0.5.1: fix stop()0.5.1
-rw-r--r--aioeventlet.py6
-rw-r--r--doc/changelog.rst8
-rw-r--r--doc/conf.py2
-rw-r--r--setup.py2
4 files changed, 16 insertions, 2 deletions
diff --git a/aioeventlet.py b/aioeventlet.py
index 9acba3d..7873544 100644
--- a/aioeventlet.py
+++ b/aioeventlet.py
@@ -206,6 +206,12 @@ class EventLoop(asyncio.SelectorEventLoop):
if eventlet.patcher.is_monkey_patched('thread'):
self._default_executor = _TpoolExecutor(self)
+ def stop(self):
+ super(EventLoop, self).stop()
+ # selector.select() is running: write into the self-pipe to wake up
+ # the selector
+ self._write_to_self()
+
def call_soon(self, callback, *args):
handle = super(EventLoop, self).call_soon(callback, *args)
if self._selector is not None and self._selector._event:
diff --git a/doc/changelog.rst b/doc/changelog.rst
index ef5e6cf..8ff3f58 100644
--- a/doc/changelog.rst
+++ b/doc/changelog.rst
@@ -1,6 +1,14 @@
Changelog
=========
+2016-02-22: Version 0.5.1
+-------------------------
+
+* Fix EventLoop.stop() for the new semantics of stop() introduced
+ in Python 3.4.4 and Python 3.5.1. The method now writes into the self-pipe
+ to wake-up the event loop. Otherwise, the stop() may not be taken in account
+ immediatly, and even block forever.
+
2016-02-22: Version 0.5
-----------------------
diff --git a/doc/conf.py b/doc/conf.py
index bd57918..ca5eebc 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -52,7 +52,7 @@ copyright = u'2014, Victor Stinner'
#
# The short X.Y version.
# The full version, including alpha/beta/rc tags.
-version = release = '0.6'
+version = release = '0.5.1'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
diff --git a/setup.py b/setup.py
index 776720b..cd6ace7 100644
--- a/setup.py
+++ b/setup.py
@@ -55,7 +55,7 @@ with open("README") as fp:
install_options = {
"name": "aioeventlet",
- "version": "0.6",
+ "version": "0.5.1",
"license": "Apache License 2.0",
"author": 'Victor Stinner',
"author_email": 'victor.stinner@gmail.com',