-
-
Notifications
You must be signed in to change notification settings - Fork 81
Closed
Labels
type-bugBug reportBug report
Milestone
Description
Reviewing Marc's docstring update work, I saw that unwatch apparently logs a warning if it fails at removing a watcher, there has to be a better way, e.g. raising a LookupError.
def unwatch(self_, watcher):
"""Remove the given Watcher object (from `watch` or `watch_values`) from this object's list."""
try:
self_._register_watcher('remove', watcher, what=watcher.what)
except Exception:
self_.warning(f'No such watcher {str(watcher)} to remove.')Metadata
Metadata
Assignees
Labels
type-bugBug reportBug report