Start Run with Agentic Harness on the change it was opened for - #201
Closed
VeryComplexAndLongName wants to merge 3 commits into
Closed
Start Run with Agentic Harness on the change it was opened for#201VeryComplexAndLongName wants to merge 3 commits into
VeryComplexAndLongName wants to merge 3 commits into
Conversation
The change was implemented and its directory moved to archive/ on disk, but the deletion of the original path was left unstaged - so the old files stayed git-tracked while missing from the working tree, and check-english.mjs died with ENOENT before eslint ever ran. That is the same failure that made npm run lint expected-red for days earlier this week, from the same cause: an archive move committed halfway. Staging both halves together is what keeps the check meaningful. 31 of 31 tasks complete, archive copy verified intact. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Right-clicking a change and choosing Run with Agentic Harness opened a
panel with nothing filled in: command `list`, no change selected, default
agent. The user re-entered what they had just said by right-clicking.
Everything needed was already there. runWithHarness passes the change -
revealAiPanel({ ...dashboardContext(workspaceRoot, item.changeDir),
startChain }) - and AiPanel takes changeDir as a prop. It simply started
from useState("list") and useState("") and never consulted it.
The agent is the same fact one step further on. AiPanel already
pre-selects from stepAgents, keyed on the command kind through
COMMAND_KIND_TO_HARNESS_STAGE. With the kind stuck at `list` there is no
stage, so no entry is looked up and the picker keeps DEFAULT_AGENT_ID.
Seeding the kind fixes the agent as a consequence - the configured agent
was never unavailable, only unreachable. One defect, three symptoms.
Seeding the selection alone was not enough, and the test caught it: a
<select> cannot hold a value it has no option for, so the seeded change
silently fell back to empty until a `list` had run. The option list is
seeded too, and the existing reconciling effect replaces it with the real
list while keeping the selection.
Nothing is enforced. Every seeded value stays editable, the same way the
stepAgents agent recommendation already was. The chain path is untouched:
a config resolving to `chain` mounts HarnessChainPanel, which has one
button and nothing to pre-select, so `runChange` is set only for the
picker target.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Owner
Author
|
Superseded by a branch rebased onto main. The original branch was cut from a sibling branch whose commit later landed on main as #200 (squashed), so the same content appeared twice and the pull request conflicted before CI could start. |
VeryComplexAndLongName
deleted the
feat/run-with-harness-prefills-the-run
branch
September 5, 2026 05:44
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.
Two commits: the archive move that was blocking
npm run lint, and the prefill itself.The prefill — one defect, three symptoms
Right-clicking a change and choosing Run with Agentic Harness opened a panel with nothing filled in: command
list, no change selected, default agent.Everything needed was already there.
runWithHarnesspasses the change:and
AiPaneltakeschangeDiras a prop. It simply started fromuseState<CommandKind>("list")anduseState<string>("")and never consulted it.The agent is the same fact one step further on.
AiPanelalready pre-selects fromstepAgents, keyed on the command kind throughCOMMAND_KIND_TO_HARNESS_STAGE. With the kind stuck atlistthere is no stage, so no entry is looked up and the picker keepsDEFAULT_AGENT_ID.Seeding the kind fixes the agent as a consequence — the configured agent was never unavailable, only unreachable.
What the test caught
Seeding the selection alone was not enough:
A
<select>cannot hold a value it has no<option>for, so the seeded change silently fell back to empty until alisthad run. The option list is seeded too now, and the existing reconciling effect replaces it with the real list while keeping the selection.Nothing is enforced — every seeded value stays editable, the same way the
stepAgentsrecommendation already was. The chain path is untouched:runChangeis set only for the picker target, sinceHarnessChainPanelhas one button and nothing to pre-select.The archive move
dispatch-to-chat-integration-coveragewas implemented and its directory moved toarchive/on disk, but the deletion of the original path was left unstaged — so the old files stayed git-tracked while missing from the working tree, andcheck-english.mjsdied withENOENTbefore eslint ever ran.That is the same failure that made
npm run lintexpected-red for days earlier this week, from the same cause: an archive move committed halfway. Staged both halves; 31/31 tasks complete, archive copy verified intact.Staging it also surfaced a real
no-useless-escapeerror in my own new test, which had been hidden behind that ENOENT — the precise reason this matters.Test plan
npm run typecheck— cleannpm run lint— clean (0 errors), once the archive move was stagedAiPanel43/43,extension-context7/7openspec change validate --strict— validgit.push.test.ts, tracked ascore-test-worker-contentionimplementand the configured agent are already selected, and that changing any of them still works🤖 Generated with Claude Code