basquetWi + New ticket
agent-ops OPS-267

scrp-monitor-agent-idle.sh runtime= is name-derived but reads as measured, and its one real cross-check false-signals on stale scrollback

Done normal bvbin-venus-cc

scrp-monitor-agent-idle.sh lines 193-202 set RUNTIME from the agent-name suffix (*-cc=claude, *-ca=codex), not from the pane. The header comment is honest about this, but the OUTPUT FIELD is named runtime= and reads exactly like a measurement - I reported 'runtime=codex, measured' to Elazar off it, when it was the naming convention read back to me. A field that restates the convention you are trying to verify is not evidence. The script DOES compute a real signal separately as SEEN (matches 'Ask Codex to do anything', '. Ready', '. Working' vs claude markers) but only surfaces it as pane_looks_like= ON DISAGREEMENT, so the corroborating evidence is invisible whenever it agrees and the derived field silently takes the credit. Second half, measured by bin-whey-cc on whey: the cross-check FALSE-SIGNALS - bin-whey-ca is genuinely codex (pane process is the codex binary, CODEX_AGENT_NAME=bin-whey-ca in its environ) yet SEEN matched stale Claude-style scrollback and reported pane_looks_like=claude. So the one branch that could contradict the suffix is itself unreliable on a pane with old scrollback. Ask: surface the pane-derived value ALWAYS, not only on disagreement, and make the scrollback match resistant to stale content. Do not simply trust the suffix harder. Context: this matters now because Elazar has shifted fleet work onto codex seats and runtime identification is how we tell which budget a seat spends.

Sub-tickets

No sub-tickets.
+ Add sub-ticket

Activity

  • wi-cli-venus created · 4w ago
  • wi-cli-venus completed · 4w ago
    DONE 2026-09-18, v2.8, sh.git 2baff04. BOTH ASKS SHIPPED. (1) runtime_src= and pane_looks_like= are emitted on EVERY line, agreeing or not, so a corroborated verdict is no longer indistinguishable from an unexamined one; NOT-FOUND/TIMEOUT carry pane_looks_like=no-pane, because no pane read is a different fact from a pane read that matched nothing. (2) The match is scoped to the LIVE CHROME - last 5 non-blank lines - instead of the whole 20-line tail, which was mostly history. FORCED, NOT OBSERVED. Built a real tmux pane in the whey shape (genuinely -ca, stale Claude scrollback, codex status line not in the capture): prior matcher returns pane_looks_like=claude - the exact false signal bin-whey-cc measured - and v2.8 returns unknown. The VERDICT does not move, because the name still picks the parser; what changes is that the evidence field no longer lies. Window size derived by measurement, not choice: five live venus panes plus two synthesized dialog states, live chrome within the last 5 non-blank lines on every one, including claude plan-pending (the approval selector is itself a prompt glyph). REJECTED BY MEASUREMENT - do not re-propose: adding "(shift+tab to cycle)" to the claude pattern set to widen dialog coverage. Claude-only and bottom-of-pane, so it reads as the obvious win, but it is also the most common residue in a codex pane's stale scrollback and it re-introduced the false signal on BOTH stale fixtures (one codex->both, one unknown->claude). TWO DEFECTS THE FORCING EXPOSED, fixed in the same version. (a) A regression I ADDED: the new CHROME assignment aborts under the file's own set -euo pipefail on an ALL-BLANK pane - grep -v matches nothing, pipefail promotes it, script exits rc=1 with NO OUTPUT, which a caller reads as BUSY. Blank panes are real and v2.7 printed a line for them. Only the forced no-marker control caught it. Correction to my own reasoning in the same turn: "grep -q ... && var=1" does NOT abort under set -e, so the dangerous construct was the one added to HOLD the evidence, not the one I was watching. (b) The codex branch parsed model/cwd with a bare grep for one interpunct over the whole tail; on the repro pane it returned a dead Claude mode line as model/cwd. Scoping to CHROME alone did not cure it - that line is INSIDE the live window - so the discriminator is structural: a codex status line carries at least two separators, the Claude mode line exactly one. No match now says codex_status=absent, and STATE stays BUSY because codex idle is matched positively. COVERAGE STATEMENT. Exercised on venus: 5 live panes (1 codex IDLE, 3 claude IDLE, 1 claude BUSY), a NOT-FOUND, a blank pane, and a synthesized whey-shape codex pane - verdicts and parsed fields unchanged on every live pane before and after. NOT exercised: a real permission-dialog pane with no prompt glyph, which reports pane_looks_like=unknown under both the old and new rules. That blind spot is PRE-EXISTING and is now visible rather than silently absent; it is not a regression and it is not verified absent. Also not exercised: a real -ca pane on whey, since venus's only codex seat is db03-mars-ca.
bug
4w ago by wi-cli-venus
4w ago
2026-09-18 08:15