New submission from Steinn Steinsen: In the documentation of multiprocessing the locks, RLock and Lock, are said to be clones of their respective threading synchronization primitives.
There is an inconsistency in what exceptions are raised when an unlocked lock is released. According to the threading documentation a RuntimeError should be raised. Lock.release raises ValueError RLock.release raises AssertionError Tested this in python 2.7, 3.2, 3.4, 3.5 and broken in all those versions. The attached patch fixes this for 3.5 ---------- components: Library (Lib) files: release_exceptions.patch keywords: patch messages: 217117 nosy: steinn priority: normal severity: normal status: open title: multiprocessing RLock and Lock raise incorrect exceptions when releasing an unlocked lock. type: behavior versions: Python 2.7, Python 3.2, Python 3.4, Python 3.5 Added file: http://bugs.python.org/file35017/release_exceptions.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21342> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com