fix(codemode): bound eval status history on current main#334
Draft
minpeter wants to merge 2 commits into
Draft
Conversation
Contributor
Author
|
CI follow-up for the replacement delivery: run 30110526214 passed Check, the workspace build, all three terminal-platform jobs, GitGuardian, and the Code Mode suite (55 files / 384 tests). The broad workspace Test step is red in |
This was referenced Jul 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Root cause
Each eval cell retained every status event, including a path and preview for every
read(). Every partial update then copied the entire unbounded history into both top-level and cell details. Read-heavy child work could therefore exhaust V8's heap before eval completed.Current-main replacement
This Draft is based directly on
upstream/main@38bd3a3cfand contains patch-identical ports of the two focused commits from #324. No current-main source file touched by the fix diverged from #324's old base.Supersedes #324, which was 21 main commits behind and did not contain current
mainin its ancestry.Verification
npm run build: passed@code-yeongyu/senpi-codemodesource suite: 54 files / 372 tests passed; 1 file / 12 tests capability-skippednpm run check: passedgit diff --check: passedExact 256 MB source CLI QA
Run from the PR worktree root through the Senpi QA harness and real source CLI (
runCli/tsx) with a hermetic localhost fake-model provider:Results:
read()events: PASS in 5.232 s; 100 top-level rows; 100 cell rows; exact omitted count 26read()events: PASS in 7.735 s; 100 top-level rows; 100 cell rows; exact omitted count 19,901Red
Check and testclassificationThe historical check remains red and is not represented as passing. Its two
packages/coding-agentfailures were compared against freshupstream/main@38bd3a3cf, which is still the PR's exact base:git diff --stat upstream/main...HEAD -- packages/coding-agentis empty; the failing tests, Vitest config, andsrc/main.tshave identical hashes at PR head and base.30089381490has the same test,expected [] to have a length of 2 but got +0assertion, and line 1361 as PR run30110526214. Fresh focused runs fail identically at both PR head and a clean detached base worktree; fresh serializedCI=1 npm testruns fail it on both revisions. Classification: pre-existing current-main failure.No unrelated
coding-agentfix is included in this scoped Code Mode OOM PR.Local evidence:
local-ignore/qa-evidence/20260724-eval-status-history-current-main/INDEX.mdandci-failure-classification.md.Summary by cubic
Bound each eval cell’s status history to 100 rows and added an omission marker to prevent heap bloat during read‑heavy evaluations while keeping the newest events intact.
status-events.tswithSTATUS_EVENT_HISTORY_LIMIT = 100; keep the latest 99 events plus a{ op: "status-events-omitted", count }row.agentcoalescing remains.render.tsas “N earlier events omitted”.@code-yeongyu/senpi-codemodeto document and verify bounded history.Written for commit 48dbede. Summary will update on new commits.