classification
Title: No such class: multiprocessing.pool.AsyncResult
Type: Stage: resolved
Components: Documentation Versions: Python 3.10, Python 3.9, Python 3.8, Python 3.7, Python 3.6, Python 3.5
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: Volker Weißmann, docs@python, python-dev, remi.lapeyre, sbt, tkf
Priority: normal Keywords: patch

Created on 2013-04-20 21:44 by tkf, last changed 2020-07-03 11:31 by Volker Weißmann. This issue is now closed.

Files
File name Uploaded Description Edit
ApplyResult.patch tkf, 2013-04-20 21:44
Pull Requests
URL Status Linked Edit
PR 21291 merged Volker Weißmann, 2020-07-03 11:31
Messages (6)
msg187466 - (view) Author: Takafumi Arakaki (tkf) Date: 2013-04-20 21:44
Document mentions AsyncResult but there is no such class.
http://docs.python.org/2/library/multiprocessing.html#multiprocessing.pool.AsyncResult

You can check it by simply running:
python -c 'from multiprocessing.pool import AsyncResult'

I think it means ApplyResult so I made a patch (attached).

Note that there managers.py also uses name 'AsyncResult':
% hg grep AsyncResult
Doc/library/multiprocessing.rst:83232:.. class:: AsyncResult
Lib/multiprocessing/managers.py:81039:    'apply_async': 'AsyncResult',
Lib/multiprocessing/managers.py:81039:    'map_async': 'AsyncResult',
Lib/multiprocessing/managers.py:81039:    'starmap_async': 'AsyncResult',
Lib/multiprocessing/managers.py:81039:SyncManager.register('AsyncResult', create_method=False)

Probably renaming them would be better?
msg188265 - (view) Author: Richard Oudkerk (sbt) * (Python committer) Date: 2013-05-02 13:26
It might be simplest to make the implementation match the docs by making AsyncResult an alias for ApplyResult.
msg188510 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013-05-06 11:15
New changeset 2684176519ef by Richard Oudkerk in branch '2.7':
Issue #17805: Add AsyncResult alias for ApplyResult
http://hg.python.org/cpython/rev/2684176519ef

New changeset bb4bb2db6106 by Richard Oudkerk in branch '3.3':
Issue #17805: Add AsyncResult alias for ApplyResult
http://hg.python.org/cpython/rev/bb4bb2db6106
msg372889 - (view) Author: Volker Weißmann (Volker Weißmann) * Date: 2020-07-02 22:10
The documentation here: https://docs.python.org/3/library/multiprocessing.html#module-multiprocessing.pool
says that apply_async is "A variant of the apply() method which returns a result object."
You should replace "a result object" with "a AsyncResult/ApplyResult object" and a link to https://docs.python.org/2/library/multiprocessing.html#multiprocessing.pool.AsyncResult
msg372891 - (view) Author: Rémi Lapeyre (remi.lapeyre) * Date: 2020-07-02 22:12
Hi Volker Weißmann, this issue has been closed for 7 years, if you want to propose a change, please open a new issue.
msg372893 - (view) Author: Volker Weißmann (Volker Weißmann) * Date: 2020-07-02 23:39
Tomorror, or in a few days, I'm gonna create a pullrequest for it.
History
Date User Action Args
2020-07-03 11:31:44Volker Weißmannsetpull_requests: + pull_request20440
2020-07-02 23:39:59Volker Weißmannsetmessages: + msg372893
2020-07-02 22:12:36remi.lapeyresetnosy: + remi.lapeyre
messages: + msg372891
2020-07-02 22:10:37Volker Weißmannsetnosy: + Volker Weißmann

messages: + msg372889
versions: + Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9, Python 3.10, - Python 2.7, Python 3.3, Python 3.4
2013-05-06 11:27:26sbtsetstatus: open -> closed
resolution: fixed
stage: resolved
2013-05-06 11:15:19python-devsetnosy: + python-dev
messages: + msg188510
2013-05-02 13:26:29sbtsetmessages: + msg188265
2013-04-20 22:07:18ned.deilysetnosy: + sbt

versions: - Python 2.6, Python 3.1, Python 3.2, Python 3.5
2013-04-20 21:44:09tkfcreate