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 davin
Recipients davin, docs@python, max
Date 2017-03-11.20:46:22
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1489265183.45.0.907010686151.issue29795@psf.upfronthosting.co.za>
In-reply-to
Content
On Windows, because that OS does not support fork, multiprocessing uses spawn to create new processes by default.  Note that in Python 3, multiprocessing provides the user with a choice of how to create new processes (i.e. fork, spawn, forkserver).

When fork is used, the 'q = Queue()' in this example would be executed once by the parent process before the fork takes place, the resulting child process continues execution from the same point as the parent when it triggered the fork, and thus both parent and child processes would see the same multiprocessing.Queue.  When spawn is used, a new process is spawned and the whole of this example script would be executed again from scratch by the child process, resulting in the child (spawned) process creating a new Queue object of its own with no sense of connection to the parent.


Would you be up for proposing replacement text to improve the documentation?  Getting the documentation just right so that everyone understands it is worth spending time on.
History
Date User Action Args
2017-03-11 20:46:23davinsetrecipients: + davin, docs@python, max
2017-03-11 20:46:23davinsetmessageid: <1489265183.45.0.907010686151.issue29795@psf.upfronthosting.co.za>
2017-03-11 20:46:23davinlinkissue29795 messages
2017-03-11 20:46:22davincreate