stop and join watchdog observer (#11706)
This is in accordance with the example. For inotify at least the `.stop()`
call ends up calling the removed unschedule call anyways.
72f2eb7203 (example-api-usage)
This commit is contained in:
parent
69ea31f509
commit
61fa0edc02
|
@ -174,7 +174,8 @@ class FileKeyring(FileSystemEventHandler):
|
|||
|
||||
def cleanup_keyring_file_watcher(self):
|
||||
if getattr(self, "keyring_observer"):
|
||||
self.keyring_observer.unschedule_all()
|
||||
self.keyring_observer.stop()
|
||||
self.keyring_observer.join()
|
||||
|
||||
def on_modified(self, event):
|
||||
self.check_if_keyring_file_modified()
|
||||
|
|
Loading…
Reference in New Issue