Issue 15064: Use context manager protocol for more multiprocessing types (original) (raw)
Issue15064
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.
This issue has been migrated to GitHub: https://github.com/python/cpython/issues/59269
classification
Title: | Use context manager protocol for more multiprocessing types | ||
---|---|---|---|
Type: | enhancement | Stage: | resolved |
Components: | Versions: | Python 3.3 |
process
Status: | closed | Resolution: | fixed |
---|---|---|---|
Dependencies: | Superseder: | ||
Assigned To: | Nosy List: | dan.oreilly, ned.deily, python-dev, sbt, tshepang | |
Priority: | normal | Keywords: |
Created on 2012-06-14 12:13 by sbt, last changed 2022-04-11 14:57 by admin. This issue is now closed.
Messages (5) | ||
---|---|---|
msg162776 - (view) | Author: Richard Oudkerk (sbt) * ![]() |
Date: 2012-06-14 12:13 |
There are some types which should support the context manager protocol: - connection objects - listener objects - pool objects | ||
msg163107 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2012-06-18 16:55 |
New changeset 6d2a773d8e00 by Richard Oudkerk in branch 'default': Issue #15064: Implement context manager protocol for multiprocessing types http://hg.python.org/cpython/rev/6d2a773d8e00 | ||
msg163119 - (view) | Author: Roundup Robot (python-dev) ![]() |
Date: 2012-06-18 20:31 |
New changeset 198382b4bcd0 by Richard Oudkerk in branch 'default': Issue #15064: Make BaseManager.__enter__() start server if necessary. http://hg.python.org/cpython/rev/198382b4bcd0 New changeset 836d712461b3 by Richard Oudkerk in branch 'default': Issue #15064: Use with-blocks for some examples in docs. http://hg.python.org/cpython/rev/836d712461b3 | ||
msg242120 - (view) | Author: Dan O'Reilly (dan.oreilly) * | Date: 2015-04-27 15:07 |
It's probably too late to do anything about this now, but wouldn't it make more sense for `Pool.__exit__` to call `close`, rather than `terminate`? The vast majority of the time, that's probably what the user of the `Pool` would want to run. It also would make the behavior consistent with `concurrent.futures.ProcessPoolExecutor`, which will always wait for pending tasks to complete before exiting the `with` block. | ||
msg242162 - (view) | Author: Ned Deily (ned.deily) * ![]() |
Date: 2015-04-28 01:38 |
Dan, this issue was closed and the code associated with it released a few years ago. Comments here will likely be ignored. If you want to pursue your suggestion, please open a new issue for it. |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-11 14:57:31 | admin | set | github: 59269 |
2020-10-20 19:44:15 | iritkatriel | link | issue23510 superseder |
2015-04-28 01:38:05 | ned.deily | set | nosy: + ned.deilymessages: + |
2015-04-27 15:07:10 | dan.oreilly | set | nosy: + dan.oreillymessages: + |
2012-06-19 13:20:14 | sbt | set | status: open -> closedtitle: multiprocessing should use more context manager -> Use context manager protocol for more multiprocessing typesresolution: fixedstage: needs patch -> resolved |
2012-06-18 20:31:54 | python-dev | set | messages: + |
2012-06-18 16:55:39 | python-dev | set | nosy: + python-devmessages: + |
2012-06-15 16:27:03 | tshepang | set | nosy: + tshepang |
2012-06-14 12:13:45 | sbt | create |