Stabilize dev green and canonical agent recovery#342
Conversation
OpenCode CLI's TUI enables mouse tracking for click-handling, which caused the fallbackToCursorKeysWhenAltScreenMouseCapture policy to intercept scroll events and send up/down arrow keys instead. The CLI doesn't interpret arrow keys as scroll commands, so scrolling broke. Change scrollInputPolicy to 'native' so xterm.js passes mouse scroll SGR sequences through to the CLI, letting it handle them natively.
…creen - Skip term.scrollLines() in alt screen for touch scrolling (it's a no-op since alternate buffer has no scrollback) - Update opencode scroll/touch test fixtures and assertions to match the new native policy: OpenCode no longer translates scroll events to cursor keys
# Conflicts: # server/coding-cli/codex-app-server/launch-planner.ts # server/coding-cli/codex-app-server/runtime.ts # server/index.ts # test/unit/server/coding-cli/codex-app-server/launch-planner.test.ts # test/unit/server/coding-cli/codex-app-server/runtime.test.ts
|
Latest investigation update:
|
This reverts commit 3625e4f.
|
Task 10 update: the fresh-agent/canonical recovery portion of this stale dev-stack carrier is superseded by #351: #351 #351 is built on #350 and preserves the selected fresh-agent/canonical recovery content from This only supersedes the fresh-agent/canonical recovery slice. Codex durability, OpenCode residuals, and the remaining #342 content still need separate handling, so I am not closing #342. |
|
Split update: #352 now supersedes the Codex/app-server durability portion of this stale dev-stack carrier only. Preserved source commits/content from #342: #342 should remain open until the remaining non-Codex portions are superseded separately. |
|
Task 12 update: the OpenCode/restore/activity residual portion of this dev-stack carrier has been split to PR #353: #353 Preserved in #353:
Intentionally not duplicated:
I am leaving #342 open rather than closing it in this step because the known supersession map now spans #336, #348, #350, #351, #352, #353, and #333 for the recency sidecar. I do not want to close the stale carrier without a final owner confirmation that no non-listed dev-stack payload remains. |
|
Final stale-carrier audit before parity rebuild: I am not closing this PR yet. Verified covered/superseded slices:
Remaining content I could not find in an open main-target replacement PR:
Leaving #342 open until those payloads are either ported to main-target PRs or explicitly dropped. |
|
Task 15 update: opened #355 (#355) as the clean main-targeted replacement for the #331 compact tabs-registry device snapshots payload currently embedded in this stale dev-stack PR. #355 ports only the compact tabs-registry/device snapshot content and intentionally leaves #335 multi-row tabs and the other dev-only payloads out of scope. |
|
Task 16 final update: #356 (#356) supersedes the #335 multi-row tabs setting payload from this stale dev-stack carrier. It ports source #335 commit With #355 covering the #331 compact tabs-registry device snapshots payload, the two remaining gaps identified in the final stale-carrier audit are now covered by clean main-targeted PRs. The earlier comments already map the other #342 slices to their replacement PRs (#350/#351/#354, #352, #353/#348, #336/#338, #332/#333/#349). Closing #342 as fully superseded. Please review/merge the replacement PRs rather than this stale dev-stack PR. |
Summary
Context
Red/Green Evidence
npm run test:vitest -- test/unit/server/fresh-agent/production-wiring.test.ts test/unit/server/ws-handler-fresh-agent.test.ts test/unit/server/coding-cli/codex-app-server/legacy-sidecar-dead-code.test.ts test/unit/server/coding-cli/codex-app-server/launch-retry.test.ts --runfailed before the implementation on production Fresh Agent wiring, fresh-agent cache cleanup, and legacy sidecar file presence. The launch-retry test passed immediately because that claim was a missing direct coverage claim, not a runtime behavior bug./home/user/code/freshell/.worktrees/dev-green-20260516.Verification
/home/user/code/freshell/.worktrees/dev-green-20260516:npm run test:vitest -- test/unit/server/fresh-agent/production-wiring.test.ts test/unit/server/ws-handler-fresh-agent.test.ts test/unit/server/coding-cli/codex-app-server/legacy-sidecar-dead-code.test.ts test/unit/server/coding-cli/codex-app-server/launch-retry.test.ts --run/home/user/code/freshell/.worktrees/dev-green-20260516:npm run test:vitest -- test/unit/server/fresh-agent/runtime-manager.test.ts test/unit/server/fresh-agent/router.test.ts test/unit/server/fresh-agent/claude-adapter.test.ts test/unit/server/fresh-agent/codex-adapter.test.ts test/unit/server/coding-cli/codex-app-server/runtime.test.ts test/unit/server/coding-cli/codex-app-server/client.test.ts test/unit/server/coding-cli/codex-app-server/launch-planner.test.ts --run/home/user/code/freshell/.worktrees/dev-green-20260516:FRESHELL_TEST_SUMMARY="verify fresh-agent PR review corrections" npm run checknpm run test:vitest -- test/integration/real/coding-cli-session-contract.test.ts --run,npm run test:vitest -- test/unit/server/coding-cli/codex-app-server/runtime.test.ts --run, andnpm run test:vitest -- test/integration/real/codex-app-server-readiness-contract.test.ts --run