- 12 Jan, 2018 5 commits
-
-
Jason Madden authored
It depended on when the timer expired relative to when we intered the loop for the first time. It could still run before our other callbacks did if it had expired before we entered the loop. I suppose that going to the static 'extern' functions changed the timing of things enough that this exposed itself.
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
I'll need help to reproduce them. But temporarily add some extra debugging to the makefile to see if we get a clue. The cpython failure in test_subprocess.py definitely began with this branch (which doesn't make much sense). The PyPy failure was happening long before.
-
- 11 Jan, 2018 2 commits
-
-
Jason Madden authored
-
Jason Madden authored
-
- 10 Jan, 2018 5 commits
-
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
Skip that one test that fails on Python 3.7 under libuv on Travis. It doesn't fail for any other CPython version there and it doesn't fail locally. Chalking it up to a alpha issue for now.
-
Jason Madden authored
-
Jason Madden authored
Instead of manually having it schedule callbacks, we instead run callbacks at a time in the event loop cycle equivalent to when libev runs them. We do this with a check watcher (instead of a 0 duration timer). Fixes #1058
-
- 09 Jan, 2018 6 commits
-
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
The good news is this probably explains a lot of the timer oddities we see under libuv (see detailed comments in the code). The bad news is it means we need to rethink some things for libuv.
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
Test all backends that are supported with the full test suite in a single run. We have a high setup overhead, so not only does this reduce the number of jobs, it hopefully reduces the overall time taken, while actually increasing the number of tests run.
-
- 08 Jan, 2018 7 commits
-
-
Jason Madden authored
Support for Python 3.7
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
No new unexpected failures. Rename the 'async' methods and classes to 'async_'. I couldn't think of a better name. But keep the old names available for BWC. Fixes #1047.
-
- 02 Jan, 2018 1 commit
-
-
Jason Madden authored
Request more specifics.
-
- 22 Dec, 2017 6 commits
-
-
Jason Madden authored
Explicitly close IO watchers
-
Jason Madden authored
Disable PyPy+libuv on Windows again, still some very strange errors there. But PyPy+libuv on darwin/posix works, and CPython3.6 Windows works. Perhaps the issue is the 32-bit pypy on windows and the way it adjusts socket.fileno()?
-
Jason Madden authored
-
Jason Madden authored
Hopefully solve the test__os issue. It turned out to be that calling uv_close at random GC times is a very bad idea under libuv. See the comment. Try enabling pypy+libuv on posix and windows; it's working on darwin for me.
-
Jason Madden authored
-
Jason Madden authored
By closing them when we're done, we can remove reliance on GC to clean up multiplexed watchers and solve problems for PyPy and Windows (and probably eventually simplify the handle cleanup we were doing.) This makes many more tests on PyPy pass on Darwin; down from a score of failures to about 4, but a baffling 4. test__os:TestOS_nb times out; investigation shows that both the read and write sides of the pipe are waiting on events, both are in libuv, and the write side should be writable, but it's not getting an event. Not clear why this is. I also see it with CPython 3.6, and I don't think I did before.
-
- 15 Dec, 2017 4 commits
-
-
Jason Madden authored
-
Jason Madden authored
Support libuv under CPython 3.6 on Windows
-
Jason Madden authored
First the crash report: ``` testInterruptedRecvmsgTimeout (__main__.InterruptedRecvTimeoutTest) ... Traceback (most recent call last): File "/home/travis/build/gevent/gevent/src/gevent/_ffi/loop.py", line 83, in python_callback def python_callback(self, handle, revents): File "/home/travis/build/gevent/gevent/src/greentest/3.6/test_socket.py", line 3698, in <lambda> lambda signum, frame: 1 / 0) ZeroDivisionError: division by zero Fri Dec 15 16:09:36 2017 ok testInterruptedSendTimeout (__main__.InterruptedSendTimeoutTest) ... Fatal Python error: ffi.from_handle() detected that the address passed points to garbage. If it is really the result of ffi.new_handle(), then the Python object has already been garbage collected Thread 0x00002b26d4c01700 (most recent call first): File "/home/travis/build/gevent/gevent/src/gevent/_threading.py", line 152 in wait File "/home/travis/build/gevent/gevent/src/gevent/_threading.py", line 436 in get File "/home/travis/build/gevent/gevent/src/gevent/threadpool.py", line 200 in _worker Thread 0x00002b26d4a00700 (most recent call first): File "/home/travis/build/gevent/gevent/src/gevent/_threading.py", line 152 in wait File "/home/travis/build/gevent/gevent/src/gevent/_threading.py", line 436 in get File "/home/travis/build/gevent/gevent/src/gevent/threadpool.py", line 200 in _worker Current thread 0x00002b26cc7b2a00 (most recent call first): File "/home/travis/build/gevent/gevent/src/gevent/_ffi/loop.py", line 178 in python_stop File "/home/travis/build/gevent/gevent/src/gevent/libuv/loop.py", line 289 in run File "/home/travis/build/gevent/gevent/src/gevent/hub.py", line 688 in run ``` The main problem turned out to be the way in which libuv reports signals at random times, much worse than the way libev does. This led to callback functions unexpectedly returning 0, because that's the default for an unhandled exception or an onerror handler that returns None. That in turn led to calls to python_stop that we weren't expecting using a handle that had already been deallocated. The fix is to both be defensive about what handles we try to use, and to be more explicit about our error returns.
-
Jason Madden authored
Disable pypy on appveyor again because it takes too long. I need to make sure it runs on POSIX first.
-
- 14 Dec, 2017 3 commits
-
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
I solved the test_ftplib.py windows failures locally by more careful handling of lifetimes of io watchers: they should be disposed when the fileno is. I investigated a more drastic approach using new watchers entirely every time we restart, but it doesn't seem necessary, at least on CPython (I can't even run PyPy+libuv locally on darwin though, so there are more problems lurking there).
-
- 13 Dec, 2017 1 commit
-
-
Jason Madden authored
All tests are passing locally after fixing a GC-cycle related issue in the io watcher that kept the wrong socket watchers alive. This should probably be generalized to all watchers on all FFI platforms.
-