From aaf3fe394c419c724636f6b335fff6ef7086348f Mon Sep 17 00:00:00 2001 From: Jeremy McSpadden Date: Tue, 17 Mar 2026 00:09:02 -0500 Subject: [PATCH] fix: replace orphaned invalidateStateCache() calls and remove dead test - Replace 2 remaining invalidateStateCache() calls with invalidateAllCaches() in auto.ts phantom skip loop recovery paths (lines 2473, 2551) - Remove commit-message.test.ts which referenced the removed deriveCommitMessage export from auto.ts --- src/resources/extensions/gsd/auto.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/resources/extensions/gsd/auto.ts b/src/resources/extensions/gsd/auto.ts index bceaae38e..cab90b9da 100644 --- a/src/resources/extensions/gsd/auto.ts +++ b/src/resources/extensions/gsd/auto.ts @@ -2470,7 +2470,7 @@ async function dispatchNextUnit( // Milestone is complete — evicting this key would fight self-heal. // Clear skip counter and re-dispatch from fresh state. unitConsecutiveSkips.delete(idempotencyKey); - invalidateStateCache(); + invalidateAllCaches(); ctx.ui.notify( `Phantom skip loop cleared: ${unitType} ${unitId} belongs to completed milestone ${skippedMid}. Re-dispatching from fresh state.`, "info", @@ -2548,7 +2548,7 @@ async function dispatchNextUnit( : false; if (skippedMilestoneComplete2) { unitConsecutiveSkips.delete(idempotencyKey); - invalidateStateCache(); + invalidateAllCaches(); ctx.ui.notify( `Phantom skip loop cleared: ${unitType} ${unitId} belongs to completed milestone ${skippedMid2}. Re-dispatching from fresh state.`, "info",