LearnNewsExamplesServices
Frontmatter
titlefix(orchestrator): back off stuck miniSummary windows (#12828)
authorneo-gpt
stateMerged
createdAtJun 9, 2026, 9:53 PM
updatedAtJun 9, 2026, 10:05 PM
closedAtJun 9, 2026, 10:05 PM
mergedAtJun 9, 2026, 10:05 PM
branchesdevcodex/12828-backfill-no-progress
urlhttps://github.com/neomjs/neo/pull/12829
Merged
neo-gpt
neo-gpt commented on Jun 9, 2026, 9:53 PM

Resolves #12828

Authored by GPT-5 (Codex Desktop) consuming Claude Opus 4.8's handoff - session A efc94c7f-3004-42e2-89cd-ed4102d9d2d7, session B 7aedf327-ab2d-46b5-b9bb-9645334b54ca.

Adds a data-preserving no-progress backoff to the memory miniSummary backfill scheduler. When a successful backfill child exits but the same pending id window and total pending count remain, the scheduler records a bounded task-state backoff for that exact window. During the backoff the same stuck residual is not rescheduled, which frees the exclusive-heavy lane for session summarization. If new pending memories arrive or the selected window changes, the scheduler runs immediately.

Evidence: L2 (focused unit coverage for stuck-window suppression, changed-window bypass, success-hook state mutation, registry shape, and scheduling pipeline) -> L3 required (live orchestrator logs prove no repeated sub-second backfill spin and session summarization can acquire the heavy lane). Residual: post-merge live-log validation [#12828].

Deltas from ticket

The PR intentionally does not delete, tombstone, or rewrite the 3333 residual AGENT_MEMORY rows. Some are authored by @neo-gpt and may preserve valuable turns. Data classification and cleanup remain tied to #12450 / follow-up evidence work.

The raw pending count remains observable; the scheduler now treats the unchanged selected id window as temporarily stuck rather than blindly runnable every poll cycle.

Test Evidence

  • npm run test-unit -- test/playwright/unit/ai/daemons/orchestrator/scheduling/memorySummaryBackfill.spec.mjs passed before rebase: 12/12.
  • npm run test-unit -- test/playwright/unit/ai/daemons/orchestrator/scheduling/registry.spec.mjs test/playwright/unit/ai/daemons/orchestrator/scheduling/pipeline.spec.mjs passed before rebase: 12/12.
  • After rebasing onto current origin/dev: npm run test-unit -- test/playwright/unit/ai/daemons/orchestrator/scheduling/memorySummaryBackfill.spec.mjs test/playwright/unit/ai/daemons/orchestrator/scheduling/registry.spec.mjs test/playwright/unit/ai/daemons/orchestrator/scheduling/pipeline.spec.mjs passed: 24/24.
  • git diff --cached --check passed before commit.
  • Pre-push freshness check passed after rebase: merge-base HEAD origin/dev == origin/dev; outgoing log contains only 46a77dad3 fix(orchestrator): back off stuck miniSummary windows (#12828).

Post-Merge Validation

  • Restart or let the orchestrator load the merged code, then confirm a zero-drain memory-summary-backfill run records backoff instead of repeating every ~3 seconds.
  • Confirm summary can acquire the exclusive-heavy lane while the same residual backfill window is backed off.
  • Confirm new pending memories still trigger backfill immediately when they change the selected pending id window.

Commits

  • 46a77dad3 - fix(orchestrator): back off stuck miniSummary windows (#12828)

Related

Related: #12450