From f5ce55e06ffe22eeb26b91a496be6a3886b03b96 Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Sat, 20 Dec 2025 11:59:43 +0900 Subject: [PATCH] fix(todo-continuation-enforcer): show reminder only once per session with 2s countdown MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Reduce COUNTDOWN_SECONDS from 5 to 2 for faster reminder display - Remove logic that clears remindedSessions on assistant response to prevent re-triggering - Ensures todo continuation reminder displays exactly once per session 🤖 GENERATED WITH ASSISTANCE OF [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode) --- src/hooks/todo-continuation-enforcer.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/hooks/todo-continuation-enforcer.ts b/src/hooks/todo-continuation-enforcer.ts index 58e5983..223045a 100644 --- a/src/hooks/todo-continuation-enforcer.ts +++ b/src/hooks/todo-continuation-enforcer.ts @@ -62,7 +62,7 @@ function detectInterrupt(error: unknown): boolean { return false } -const COUNTDOWN_SECONDS = 5 +const COUNTDOWN_SECONDS = 2 const TOAST_DURATION_MS = 900 // Slightly less than 1s so toasts don't overlap interface CountdownState { @@ -279,11 +279,7 @@ export function createTodoContinuationEnforcer(ctx: PluginInput): TodoContinuati } } - // Clear reminded state when assistant responds (allows re-remind on next idle) - if (sessionID && info?.role === "assistant" && remindedSessions.has(sessionID)) { - remindedSessions.delete(sessionID) - log(`[${HOOK_NAME}] Cleared remindedSessions on assistant response`, { sessionID }) - } + } if (event.type === "session.deleted") {