jgehrcke / gipc

gevent-cooperative child processes and inter-process communication
https://gehrcke.de/gipc
MIT License
83 stars 13 forks source link

work in progress: gevent 20.12 #102

Closed jgehrcke closed 3 years ago

jgehrcke commented 3 years ago

For the record, the last build on Travis CI before I just force-pushed -- with relevant build failures (from 4 months ago): https://travis-ci.org/github/jgehrcke/gipc/builds/727038093

jgehrcke commented 3 years ago

Hangup, cancelled manually:

test/test_gipc.py::TestComplexUseCases::test_multi_duplex ERROR          [ 97%]
test/test_gipc.py::TestSignals::test_orphaned_signal_watcher FAILED      [ 98%]
Error: The operation was canceled.

https://github.com/jgehrcke/gipc/pull/102/checks?check_run_id=1637529375#step:5:95

Tried to reproduce locally, with a tiny but of debug-logging. Passed locally:

± pytest --log-level=debug -vvv -s -k test_orphaned_signal_watcher
====================================================================== test session starts =======================================================================
platform linux -- Python 3.8.6, pytest-4.6.9, py-1.10.0, pluggy-0.13.1 -- /home/jp/.pyenv/versions/3.8.6/envs/386-gipc-local-dev/bin/python3.8
cachedir: .pytest_cache
rootdir: /home/jp/dev/gipc
plugins: cov-2.6.1
collected 82 items / 81 deselected / 1 selected                                                                                                                  

test_gipc.py::TestSignals::test_orphaned_signal_watcher 21:53:06,657.2  [769682]test_orphaned_signal_watcher# start process
21:53:06,657.3  [769682]start_process# Invoke target `<function signals_test_child_a at 0x7f0c7556caf0>` in child process.
21:53:06,659.0  [769682]start# SIGCHLD watcher for 769725 started.
21:53:06,659.7  [769682]start_process# Invalidate <_GIPCWriter_e25db8 fd: 6> in parent.
21:53:06,659.9  [769682]close# Invalidating <_GIPCWriter_e25db8 fd: 6> ...
21:53:06,660.1  [769725]_child# _child start. target: `<function signals_test_child_a at 0x7f0c7556caf0>`
21:53:06,660.6  [769725]_child# Delete current hub's threadpool.
21:53:06,660.8  [769725]_child# Destroy hub and default loop.
21:53:06,661.0  [769725]_child# Created new hub and default event loop.
21:53:06,661.1  [769725]_child# Invalidate <_GIPCReader_3a193e fd: 5> in child.
21:53:06,661.3  [769725]_set_legit_process# Legitimate <_GIPCReader_3a193e fd: 5> for current process.
21:53:06,661.4  [769725]close# Invalidating <_GIPCReader_3a193e fd: 5> ...
21:53:06,661.5  [769725]_set_legit_process# Legitimate <_GIPCWriter_e25db8 fd: 6> for current process.
21:53:06,661.6  [769725]_child# Handle `<_GIPCWriter_e25db8 fd: 6>` is now valid in child.
21:53:06,661.9  [769682]test_orphaned_signal_watcher# send signal to child
21:53:06,662.0  [769682]test_orphaned_signal_watcher# wait for child to terminate
21:53:06,663.5  [769682]_on_sigchld# SIGCHLD watcher callback for 769725 invoked. Exitcode stored: -15
21:53:06,663.7  [769682]close# Invalidating <_GIPCReader_3a193e fd: 5> ...
21:53:06,663.8  [769682]test_orphaned_signal_watcher# cancel signal handler/watcher
PASSED

============================================================ 1 passed, 81 deselected in 0.30 seconds =============================================================