[issue16998] Lost updates with multiprocessing.Value

2013-01-21 Thread Jens Lechtenboerger
Jens Lechtenboerger added the comment: > It only says that accesses are synchronized. The problem is that you were > assuming that "+=" involves a single access -- but that is not how python > works. Yes, I understand that by now (actually since your first comment). >

[issue16998] Lost updates with multiprocessing.Value

2013-01-20 Thread Jens Lechtenboerger
Jens Lechtenboerger added the comment: > Loads and stores are both atomic. But "+=" is made up of two operations, a > load followed by a store, and the lock is dropped between the two. I see. Then this is a documentation bug. The examples in the documentation use such

[issue16998] Lost updates with multiprocessing.Value

2013-01-19 Thread Jens Lechtenboerger
New submission from Jens Lechtenboerger: Maybe I'm misreading the documentation of multiprocessing.Value and multiprocessing.sharedctypes.Value. I thought that access to the value field of Value instances was protected by locks to avoid lost updates. Specifically, for multiprocessing.

[issue16936] Documentation for stat.S_IFMT inconsistent

2013-01-11 Thread Jens Lechtenboerger
New submission from Jens Lechtenboerger: The documentation for the stat module is inconsistent (Doc/library/stat.rst, at least for Python 2.7.2 and 3.3.0): It talks about a function stat.S_IFMT() and a bit mask stat.S_IFMT. Only the former does exist. Besides, it states: "For complete de