Skip to content

Commit b952ebe

Browse files
[3.11] gh-100408: Fix a traceback in multiprocessing example (GH-100409) (GH-106231)
(cherry picked from commit a28d4ed) Co-authored-by: Serhiy Storchaka <[email protected]>
1 parent b937ca0 commit b952ebe

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Doc/library/multiprocessing.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -453,16 +453,16 @@ process which created it.
453453
... return x*x
454454
...
455455
>>> with p:
456-
... p.map(f, [1,2,3])
456+
... p.map(f, [1,2,3])
457457
Process PoolWorker-1:
458458
Process PoolWorker-2:
459459
Process PoolWorker-3:
460460
Traceback (most recent call last):
461461
Traceback (most recent call last):
462462
Traceback (most recent call last):
463-
AttributeError: 'module' object has no attribute 'f'
464-
AttributeError: 'module' object has no attribute 'f'
465-
AttributeError: 'module' object has no attribute 'f'
463+
AttributeError: Can't get attribute 'f' on <module '__main__' (built-in)>
464+
AttributeError: Can't get attribute 'f' on <module '__main__' (built-in)>
465+
AttributeError: Can't get attribute 'f' on <module '__main__' (built-in)>
466466

467467
(If you try this it will actually output three full tracebacks
468468
interleaved in a semi-random fashion, and then you may have to

0 commit comments

Comments
 (0)