| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
(GH-6079) (GH-6081)
In some conditions the standard streams will be None or closed in the child process (for example if using "pythonw" instead of "python" on Windows). Avoid failing with a non-0 exit code in those conditions.
Report and initial patch by poxthegreat..
(cherry picked from commit e756f66c83786ee82f5f7d45931ae50a6931dd7f)
|
|
|
|
|
|
|
|
|
|
|
| |
again if crashed (GH-3247) (#4254)
* bpo-31310: multiprocessing's semaphore tracker should be launched again if crashed
* Avoid mucking with process state in test.
Add a warning if the semaphore process died, as semaphores may then be leaked.
* Add NEWS entry
(cherry picked from commit cbe1756)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
necessary (GH-3246) (#4252)
* bpo-31308: If multiprocessing's forkserver dies, launch it again when necessary.
* Fix test on Windows
* Add NEWS entry
* Adopt a different approach: ignore SIGINT and SIGTERM, as in semaphore tracker.
* Fix comment
* Make sure the test doesn't muck with process state
* Also test previously-started processes
* Update 2017-08-30-17-59-36.bpo-31308.KbexyC.rst
* Avoid masking SIGTERM in forkserver. It's not necessary and causes a race condition in test_many_processes..
(cherry picked from commit fc6b348b12ad401cab0261b7b71a65c60a08c0a8)
|
|
|
|
|
|
|
|
|
|
|
| |
closed or None. (GH-4073). (#4075)
* bpo-28326: Fix multiprocessing.Process when stdout and/or stderr is closed or None. (#4073)
(cherry picked from commit daeefd2e049b74340307481112a39f77de0f4769)
* [3.6] bpo-28326: Fix multiprocessing.Process when stdout and/or stderr is closed or None. (GH-4073).
(cherry picked from commit daeefd2e049b74340307481112a39f77de0f4769)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bpo-30595: Fix multiprocessing.Queue.get(timeout) (#2027)
multiprocessing.Queue.get() with a timeout now polls its reader in
non-blocking mode if it succeeded to aquire the lock but the acquire
took longer than the timeout.
Co-Authored-By: Grzegorz Grzywacz <grzgrzgrz3@gmail.com>
(cherry picked from commit 1b7863c3b6519c6e134c28cab8b8af0dea43e375)
* bpo-30595: Increase test_queue_feeder_donot_stop_onexc() timeout (#2148)
_test_multiprocessing.test_queue_feeder_donot_stop_onexc() now uses a
timeout of 1 second on Queue.get(), instead of 0.1 second, for slow
buildbots.
(cherry picked from commit 8f6eeaf21cdf4aea25fdefeec814a1ce07453fe9)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
3.6 (#2879)
* bpo-26762: Avoid daemon process in _test_multiprocessing (#2842)
test_level() of _test_multiprocessing._TestLogging now uses regular
processes rather than daemon processes to prevent zombi processes
(to not "leak" processes).
(cherry picked from commit 06634950c553f8df83330ed468c11483b857b7dc)
* test_multiprocessing: Fix dangling process/thread (#2850)
bpo-26762: Fix more dangling processes and threads in
test_multiprocessing:
* Queue: call close() followed by join_thread()
* Process: call join() or self.addCleanup(p.join)
(cherry picked from commit d7e64d9934d86aa6173229de5af5fe908662a33a)
* test_multiprocessing detects dangling per test case (#2841)
bpo-26762: test_multiprocessing now detects dangling processes and
threads per test case classes:
* setUpClass()/tearDownClass() of mixin classes now check if
multiprocessing.process._dangling or threading._dangling was
modified to detect "dangling" processses and threads.
* ManagerMixin.tearDownClass() now also emits a warning if it still
has more than one active child process after 5 seconds.
* tearDownModule() now checks for dangling processes and threads
before sleep 500 ms. And it now only sleeps if there is a least one
dangling process or thread.
(cherry picked from commit ffb49408f0780ae80a553208aa133bc5bb3ba129)
* bpo-26762: test_multiprocessing close more queues (#2855)
* Close explicitly queues to make sure that we don't leave dangling
threads
* test_queue_in_process(): remove unused queue
* test_access() joins also the process to fix a random warning
(cherry picked from commit b4c52966c810b5c5e088fceff403247f610b7d13)
* bpo-31019: Fix multiprocessing.Process.is_alive() (#2875)
multiprocessing.Process.is_alive() now removes the process from the
_children set if the process completed.
The change prevents leaking "dangling" processes.
(cherry picked from commit 2db64823c20538a6cfc6033661fab5711d2d4585)
|
|
|
|
|
|
|
|
|
|
|
| |
multiprocessing.Queue.join_thread() now waits until the thread
completes, even if the thread was started by the same process which
created the queue.
Fix the following warning which occurs randomly when running
test_handle_called_with_mp_queue of test_logging.QueueListenerTest:
Warning -- threading_cleanup() failed to cleanup -1 threads after 4 sec (count: 0, dangling: 1)
(cherry picked from commit 3b69d911c57ef591ac0c0f47a66dbcad8337f33a)
|
|
|
|
|
|
|
|
|
|
|
| |
(#2471)
* Clear potential ref cycle between Process and Process target
Besides Process.join() not being called, this was an indirect cause of bpo-30775.
The threading module already does this.
* Add issue reference.
(cherry picked from commit 79d37ae979a65ada0b2ac820279ccc3b1cd41ba6)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#2166)
* bpo-24484: Avoid race condition in multiprocessing cleanup
The finalizer registry can be mutated while inspected by multiprocessing
at process exit.
* Use test.support.start_threads()
* Add Misc/NEWS.
(cherry picked from commit 1eb6c0074d17f4fd425cacfdda893d65f5f77f0a)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
exc (GH-1683) (#1815)
* bpo-30414: multiprocesing.Queue._feed do not break from main loop on exc
Queue background running thread was not handling exceptions correctly.
Any exception occurred inside thread (putting unpickable object) cause
feeder to finish running. After that every message put into queue is
silently ignored.
* bpo-30414: multiprocesing.Queue._feed do not break from main loop on exc
Queue background running thread was not handling exceptions correctly.
Any exception occurred inside thread (putting unpickable object) cause
feeder to finish running. After that every message put into queue is
silently ignored.
(cherry picked from commit bc50f03db4f58c869b78e98468e374d7e61f1227)
|
|
|
|
| |
Under *spawn* and *forkserver* start methods, SimpleQueue.empty() could
raise AttributeError due to not setting _poll in __setstate__.
|
|
|
|
|
|
|
|
| |
(#1454)
* bpo-30185: avoid KeyboardInterrupt tracebacks in forkserver
* Tweak comment.
(cherry picked from commit 6dd4d734ed207ba16b017e38f8909de7ef187e29)
|
|
|
|
|
| |
(GH-1110) (#1186)
(cherry picked from commit 66bffd1)
|
|
|
|
| |
an exception raised at the very first of an iterable would cause pools behave abnormally
(swallow the exception or hang)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bpo-29861: release references to multiprocessing Pool tasks (#743)
* bpo-29861: release references to multiprocessing Pool tasks
Release references to tasks, their arguments and their results as soon
as they are finished, instead of keeping them alive until another task
arrives.
* Comments in test
(cherry picked from commit 8988945cdc27ffa86ba8c624e095b51c459f5154)
* Fix Misc/NEWS (hopefully)
|
|\
| |
| |
| | |
forkserver process if a preloaded module instantiated some multiprocessing objects such as locks.
|
| |
| |
| |
| | |
forkserver process if a preloaded module instantiated some multiprocessing objects such as locks.
|
| | |
|
|\ \
| |/
| |
| | |
server to client for certain exceptions
|
| |
| |
| |
| | |
server to client for certain exceptions
|
| | |
|
|\ \
| |/
| |
| | |
messages.
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* multiprocessing: open file with closefd=False to avoid ResourceWarning
* _test_multiprocessing: open file with O_EXCL to detect bugs in tests (if a
previous test forgot to remove TESTFN)
* test_sys_exit(): remove TESTFN after each loop iteration
Initial patch written by Serhiy Storchaka.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* multiprocessing: open file with closefd=False to avoid ResourceWarning
* _test_multiprocessing: open file with O_EXCL to detect bugs in tests (if a
previous test forgot to remove TESTFN)
* test_sys_exit(): remove TESTFN after each loop iteration
Initial patch written by Serhiy Storchaka.
|
|/ |
|
| |
|
|
|
|
| |
to ASCII replacements. Original patch by Chris Angelico.
|
|
|
|
|
|
| |
array that's larger than 50% of the available RAM.
Patch by Médéric Boquien.
|
|\
| |
| |
| |
| | |
robust at shutdown. If needs to release multiple resources, they are released
even if errors are occured.
|
| |
| |
| |
| |
| | |
robust at shutdown. If needs to release multiple resources, they are released
even if errors are occured.
|
|\ \
| |/
| |
| |
| |
| | |
available.
Patch by Davin Potts.
|
| |
| |
| |
| |
| |
| | |
available.
Patch by Davin Potts.
|
|\ \
| |/
| |
| |
| | |
handle exceptions raised by an iterator. Patch by Alon Diamant and Davin
Potts.
|
| |
| |
| |
| |
| | |
handle exceptions raised by an iterator. Patch by Alon Diamant and Davin
Potts.
|
|\ \
| |/
| |
| | |
later
|
| |
| |
| |
| | |
later
|
| | |
|
| |
| |
| |
| | |
This is to keep buildbots running while we figure out the best long-term fix.
|
|\ \
| |/ |
|
| | |
|
| |
| |
| |
| | |
Followup to issue #20540; patch by Serhiy.
|
| |
| |
| |
| | |
class name instead of hardcoded one.
|
| | |
|
|\ \
| |/ |
|
| | |
|
|/
|
|
| |
primitives.
|
| |
|
| |
|
|\ |
|