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.
Created on 2017年01月17日 08:43 by Victor de la Fuente, last changed 2022年04月11日 14:58 by admin. This issue is now closed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 2480 | merged | pitrou, 2017年06月28日 20:47 | |
| Messages (5) | |||
|---|---|---|---|
| msg285623 - (view) | Author: Victor de la Fuente (Victor de la Fuente) | Date: 2017年01月17日 08:43 | |
Versions: Darwin MacBook-Pro-de-Victor.local 16.3.0 Darwin Kernel Version 16.3.0: Thu Nov 17 20:23:58 PST 2016; root:xnu-3789312~1/RELEASE_X86_64 x86_64 Python 3.6.0 (v3.6.0:41df79263a11, Dec 22 2016, 17:23:13) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin import multiprocessing as mp condition = mp.Condition() with condition: condition.notify(2) #Docs show notify(n=1) #TypeError: notify() takes 1 positional argument but 2 were given #Replacing the call with condition.notify(2): #TypeError: notify() got an unexpected keyword argument 'n' # Docs show signature: def notify(self, n=1) # But found this debugging: # multiprocessing/synchronize.py # line 211: class Condition(object): # ..... # line 271: def notify(self): #<-- ¿There is no n paramater? # ..... |
|||
| msg285625 - (view) | Author: Victor de la Fuente (Victor de la Fuente) | Date: 2017年01月17日 08:45 | |
Sorry for the typo, I meant: #Replacing the call with condition.notify(n=2): #TypeError: notify() got an unexpected keyword argument 'n' |
|||
| msg285767 - (view) | Author: Josh Rosenberg (josh.r) * (Python triager) | Date: 2017年01月19日 04:19 | |
Looks like, despite what the multiprocessing.Condition docs say (claiming it's an alias for threading.Condition), at least in Python 3.5, it's a completely separate animal from multiprocessing.synchronize, and the notify method on it doesn't take any parameters. Seems like an obvious thing to fix; the parameter is defaulted anyway, so existing code should continue to work, and it makes multiprocessing swap in for threading more seamlessly. |
|||
| msg297628 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2017年07月04日 06:59 | |
New changeset 48350412b70c76fa51f488cfc736c80d59b5e8eb by Antoine Pitrou in branch 'master': bpo-29293: multiprocessing.Condition.notify() lacks parameter `n` (#2480) https://github.com/python/cpython/commit/48350412b70c76fa51f488cfc736c80d59b5e8eb |
|||
| msg297750 - (view) | Author: STINNER Victor (vstinner) * (Python committer) | Date: 2017年07月05日 13:44 | |
New changeset 8207c17486baece8ed0ac42d9f8d69ecec4ba7e4 by Victor Stinner in branch 'master': Revert "bpo-30822: Fix testing of datetime module." (#2588) https://github.com/python/cpython/commit/8207c17486baece8ed0ac42d9f8d69ecec4ba7e4 |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:42 | admin | set | github: 73479 |
| 2017年07月05日 13:44:56 | vstinner | set | nosy:
+ vstinner messages: + msg297750 |
| 2017年07月04日 06:59:42 | pitrou | set | status: open -> closed resolution: fixed stage: resolved |
| 2017年07月04日 06:59:24 | pitrou | set | nosy:
+ pitrou messages: + msg297628 |
| 2017年06月28日 20:47:01 | pitrou | set | pull_requests: + pull_request2538 |
| 2017年06月28日 20:46:34 | pitrou | set | versions: + Python 3.7, - Python 3.6 |
| 2017年01月19日 04:19:05 | josh.r | set | nosy:
+ josh.r messages: + msg285767 |
| 2017年01月17日 08:48:45 | rhettinger | set | assignee: davin nosy: + davin |
| 2017年01月17日 08:45:03 | Victor de la Fuente | set | messages: + msg285625 |
| 2017年01月17日 08:43:56 | Victor de la Fuente | create | |