Repository navigation
Project the OpenCode pane header from the TUI process - #2018
Merged
Merged
Conversation
OpenCode 2 runs the Hearting server plugin in `serve`, whose projectPane origin proof looks for a TUI selection record named after the server pid, so it always refused (native-origin-unavailable) and no header was ever reported; the shared service's HERDR_PANE_ID is also the first TUI's pane. The TUI identity entry, which owns the selection record and its own pane, now starts the shared herdr_projection.py once when its selection moves and once per session.idle of the selected session. The V2 server plugin skips projectPane. herdr_projection's existing may_report proof is unchanged and passes (the projector's first opencode ancestor is the TUI). herdr_projection.py also assigned the display number through a relative import that fails when the file runs as a script, so the CLI reported a header without a number; it now imports fleet.session_tags absolutely. The herdr-peer-prompt scenario now also requires the pane's display_agent and title to read "[xx] <harness>". Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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.
Why
OpenCode panes never got the
[xx] opencode …header that Claude panes get. OpenCode 2 runs the Hearting server plugin insideopencode serve, soprojectPane's origin proof (tui-identity/<own pid>-<start>.json, written under the TUI's pid) never matched:native-origin-unavailable,herdr_projection.pynever started. The shared service'sHERDR_PANE_IDis also the first TUI's pane, so fixing only the proof would still aim at the wrong pane.What
hearting-tui-identity.ts(runs in the TUI, owns the selection record and its ownHERDR_PANE_ID) startstools/fleet/herdr_projection.py --harness opencode --session-id <sid> --no-report-sessiondetached, once when the selection changes and once onsession.idleof the selected session. A repeated selection starts nothing. No timer, poller, gate, setting or stored field.hearting-guards.js:projectPanereturns early for the OpenCode 2 host (it could never pass). V1 is unchanged.herdr_projection.py:_assign_observed_tagused a relative import that fails when the file runs as a script, so the CLI sent a header without the number. It now importsfleet.session_tagsabsolutely. Themay_reportproof is unchanged and passes as is (the projector's firstopencodeancestor is the TUI, and its selection record proves the session).herdr-peer-promptscenario also requiresdisplay_agentandtitleto read[xx] <harness>.Verification (isolated: throwaway HOME/XDG, private herdr server, loopback fake provider)
origin/main)display_agent/title[44] opencode/[44] opencodepane report-metadatacalls[68] claude, 3 calls[57] claude, 3 callsopencode serve[14],[99])New tests fail on
origin/mainand pass here; mutations (no projection on selection change / on idle / no same-selection filter / no V2 skip) each fail a test.What changes for users
[xx] opencode …like Claude[xx] claude …🤖 Generated with Claude Code