You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We never actually call .release() in the same function as where we acquire the lock, so the contextmanager doesn't really help here.
The owner object is there to allow the same object to acquire a given lock multiple times (acquiring a second time is a noop), but I agree we should probably just check carefully all call sites to see whether that's actually a functionality we need.
Hello @timhoffm! I'm trying to work in this issue and i'm not currently finding any occurrences of this in the codebase. This issue need to be work on the present version? If there are any occurrences plese tell me that I will enjoy to do it. Thank you!
Hi! I implemented these enter and exit methods in the LockDraw Class at widgets.py. There is enough to turn it on a context manager? Also, In exit is necessary to verify if is in the right state? Thank you!
Problem
will not release the lock properly if an exception occurs in between.
Proposed solution
We therefore should aim at
by implementing
__enter__
and__exit__
.Alternative: I'm quite unsure what the owner/available mechanism brings here. If that was not needed, we could use a standard
threading.Lock
.The text was updated successfully, but these errors were encountered: