summaryrefslogtreecommitdiffstats
path: root/Doc/library/multiprocessing.rst
diff options
context:
space:
mode:
authorRichard Oudkerk <shibturn@gmail.com>2013-07-02 11:41:00 (GMT)
committerRichard Oudkerk <shibturn@gmail.com>2013-07-02 11:41:00 (GMT)
commitb0be62453f2608e5ba0718f5c49be7e4895ae590 (patch)
treee254bca0b9502d4c5f4f94adbc5b558c64d3eeae /Doc/library/multiprocessing.rst
parent0857ab4c77d6e550a620c84e10dc2fcaf3dfad3d (diff)
parentb3c4b98c237359247d3e09d0738d308a456994a5 (diff)
downloadcpython-b0be62453f2608e5ba0718f5c49be7e4895ae590.zip
cpython-b0be62453f2608e5ba0718f5c49be7e4895ae590.tar.gz
cpython-b0be62453f2608e5ba0718f5c49be7e4895ae590.tar.bz2
Issue #17273: Clarify that pool methods can only be used by parent process.
Diffstat (limited to 'Doc/library/multiprocessing.rst')
-rw-r--r--Doc/library/multiprocessing.rst6
1 files changed, 6 insertions, 0 deletions
diff --git a/Doc/library/multiprocessing.rst b/Doc/library/multiprocessing.rst
index 95d1b1f..1078463 100644
--- a/Doc/library/multiprocessing.rst
+++ b/Doc/library/multiprocessing.rst
@@ -284,6 +284,9 @@ For example::
print(result.get(timeout=1)) # prints "100" unless your computer is *very* slow
print(pool.map(f, range(10))) # prints "[0, 1, 4,..., 81]"
+Note that the methods of a pool should only ever be used by the
+process which created it.
+
Reference
---------
@@ -1668,6 +1671,9 @@ with the :class:`Pool` class.
*initializer* is not ``None`` then each worker process will call
``initializer(*initargs)`` when it starts.
+ Note that the methods of the pool object should only be called by
+ the process which created the pool.
+
.. versionadded:: 3.2
*maxtasksperchild* is the number of tasks a worker process can complete
before it will exit and be replaced with a fresh worker process, to enable