diff --git a/src/main/automation/automation-handlers.ts b/src/main/automation/automation-handlers.ts index 46d0b06f..cc437850 100644 --- a/src/main/automation/automation-handlers.ts +++ b/src/main/automation/automation-handlers.ts @@ -31,7 +31,13 @@ export function handleTaskStatusChange( newStatus: string, ): void { if (deps.isQuitting()) return; - if (previousStatus === newStatus) return; + if (previousStatus === newStatus) { + // Caller should gate this; log the no-op so the offender can be traced. + deps.logger.warn( + `[automation] handleTaskStatusChange called with no-op status (${previousStatus}) for task ${taskId} — caller should gate this.`, + ); + return; + } const { db, wakeAgentIfPossible } = deps; const { dispatchAutomation } = callbacks;