fix(src/services): handle race condition in artwork generation and daemon cleanup

This commit is contained in:
sankalp committed 2026-07-16 12:12:15 +05:45
1 parent 19046cd1ee
commit 843c33786f
2 files changed
+16 -5

No files matched your search

+4
View File
@@ -134,6 +134,10 @@ class NightLightService(Service):
self._process.wait_async(None, self._on_daemon_exit)
def _on_daemon_exit(self, process: Gio.Subprocess, task: Gio.Task):
# Ignore exit from a stale subprocess — a new daemon may have been
# started since this one was spawned.
if self._process is not process:
return
self._process = None
self._daemon_running = False
self._set_active(False)