[issue21137] Better repr for threading.Lock()

Serhiy Storchaka report at bugs.python.org
Thu Apr 3 12:12:37 CEST 2014


Serhiy Storchaka added the comment:

The repr of threading._RLock contains owner and count, but not lock/unlock status. The repr of locks from _dummy_thread also should contain lock/unlock status. And it would be nice to have the open/closed status in the repr of other synchronization primitives: Condition, Semaphore, etc. 

As for tests, I think assertRegex() will produce more useful error report.

----------
nosy: +serhiy.storchaka
stage:  -> patch review

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue21137>
_______________________________________


More information about the Python-bugs-list mailing list