This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ffinkernagel
Recipients ffinkernagel
Date 2014-11-12.12:29:30
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1415795371.09.0.078459007626.issue22853@psf.upfronthosting.co.za>
In-reply-to
Content
If you import a module that creates a multiprocessing.Queue, puts a value, and then waits for to be received again from the queue, you run into a deadlock.

The issue is that Queue._feed does 'from .util import is_existing' - which needs the import lock, but is still being held by the main thread.

Attached a script that illustrates this.

Patch is a two line change, import is_exiting in line 49, remove the import inside the thread:

49c49
< from multiprocessing.util import debug, info, Finalize, register_after_fork
---
> from multiprocessing.util import debug, info, Finalize, register_after_fork, is_exiting
232d231
<         from .util import is_exiting
History
Date User Action Args
2014-11-12 12:29:31ffinkernagelsetrecipients: + ffinkernagel
2014-11-12 12:29:31ffinkernagelsetmessageid: <1415795371.09.0.078459007626.issue22853@psf.upfronthosting.co.za>
2014-11-12 12:29:31ffinkernagellinkissue22853 messages
2014-11-12 12:29:30ffinkernagelcreate