Skip to content

task: HITL capture for #655 Symptom A (post-#664 / #667 baseline) #668

Closed

Description

@admarble

Goal

Capture a fresh HITL terminal recording that reproduces #655 Symptom A (✔ #5loop mid-string char drop + U+FFFD overlay), under the post-#664 / post-#667 baseline. The previous capture (2026-05-17) is no longer diagnostic because both known wire-amplifiers have been removed since.

Why a fresh capture is needed

Two amplifiers that polluted the 2026-05-17 terminal.typescript have since been fixed:

Fix What it changed
#664 / PR #665 SEQUANT_DEBUG_RENDERER now writes to a file sink (.sequant/debug-renderer.jsonl), not stderr. The 2026-05-17 capture's 2,171 spurious SEQUANT WORKFLOW · lines were the stderr instrumentation co-writing to the pty — they're gone now.
#647 / PR #667 All 10 unbracketed console.log sites in phase-executor.ts retry paths + 2 batch-boundary sites in RunOrchestrator.run now route through PhasePauseHandle.appendNotice. Mechanism #2-class duplicate-header leaks from those callsites are eliminated.

Net: any Symptom A signal in a fresh capture is now isolated from the duplicate-header noise that drowned it out before. Synthetic-harness work (PR #657, #663) confirmed the symptom is NOT reproducible without real-terminal byte semantics — only an HITL capture can move this.

Capture command

DAY=$(date +%Y-%m-%d)
DIR=docs/incidents/655/captures/$DAY
mkdir -p "$DIR"

# Absolute path so the override survives the subprocess's cwd.
DEBUG_FILE="$(pwd)/$DIR/debug-renderer.jsonl"

SEQUANT_DEBUG_RENDERER=1 \
SEQUANT_DEBUG_RENDERER_FILE="$DEBUG_FILE" \
  script -q "$DIR/terminal.typescript" \
    npx sequant run <issue-or-pair> --max-iterations 1

Flag notes:

Target scenarios (in order of fidelity)

Symptom A's signature is a complete event line and a failed event line for the same issue+phase overlaid on the same row. Need a run where:

  1. An issue completes a phase then fails the next iteration of the same phase — closest fit to the original transcript (e.g., loop phase that succeeds then fails on retry). Cost: ~10–20 min real time.
  2. Resize-stress version of (1) — same scenario, resize the terminal mid-run to trigger SIGWINCH redraw races.
  3. Parallel pair with one issue retrying — broader stress, lower fidelity to the specific symptom shape.

Capture metadata (fill in after the run)

Field Value
Date / time UTC <YYYY-MM-DDTHH:MM:SSZ>
Terminal app <iTerm2 / Terminal.app / VS Code / Warp / …>
$COLUMNS × $LINES at run start <cols> × <rows>
Node version (node --version) <vXX.X.X>
sequant version (npx sequant --version) <x.y.z>
Run command (exact) <paste>
Issues fed <#NNN[, #MMM]>
Wall-clock duration <Xm Ys>
wc -l terminal.typescript <lines>
wc -l debug-renderer.jsonl <lines>
grep -c "SEQUANT_DEBUG_RENDERER" terminal.typescript should be 0 (sanity: file sink active)
Symptom A observed? yes / no / inconclusive

Acceptance criteria

  • terminal.typescript, debug-renderer.jsonl, and a populated notes.md (template above) committed to docs/incidents/655/captures/<DAY>/.
  • If symptom fires: at least one row in terminal.typescript contains both a ✔-marker substring and an error result substring (the Symptom A signature, machine-detectable via grep '✔.*error result' terminal.typescript).
  • If symptom does not fire after 3 attempts: document the non-reproducing conditions in notes.md so the next attempt can vary the right axis (terminal, width, parallelism, phase mix).

What this unblocks

Out of scope

Parent: #655. Do not run /fullsolve on #655 until a capture lands here — autonomous loops without new evidence reproduce the negative-result pattern from #657.

Activity

  1. added
    cli
    ui
    human-required
    on May 20, 2026
  2. admarble commented on May 30, 2026

    @admarble
    ContributorAuthor

    Capture delivered: docs/incidents/655/captures/2026-05-28/ (PR #673), run on two emulators (stale VS Code + fresh iTerm2). Byte stream clean on both → renderer exonerated. Full diagnosis on #655 (#655#issuecomment-4583151994). Robustness follow-up: #672.

  3. admarble commented on May 30, 2026

    @admarble
    ContributorAuthor

    QA Review — PR #673 (closes #668, satisfies #655 AC-1)

    Type: Documentation / forensic-evidence landing (5 files, +9,440, −0). No code paths touched. Branch in sync with origin, 0 behind main.

    AC Coverage

    AC Source Description Status Notes
    AC-1 #668 capture files + populated notes.md committed under docs/incidents/655/captures/<DAY>/ MET 2 captures (vscode + iterm2) × 2 files + notes.md.
    AC-2 #668 If symptom fires: row with both ✔ and error result N/A (not triggered) grep '✔.*error result' = 0/0 — symptom absent from byte stream.
    AC-3 #668 If symptom does not fire: document non-reproducing conditions MET notes.md identifies the cause with byte evidence + a concrete confirming test.
    #655 AC-1 #655 capture a real SEQUANT_DEBUG_RENDERER=1 trace from a corrupted run MET Real sequant run 593 627 on host matcha-maps; live corruption on VS Code; trace captured.

    Evidence Verification (independently reproduced)

    Every quantitative claim in notes.md re-run against the committed artifacts — all match exactly:

    Claim vscode iterm2 Verified
    typescript bytes 852,547 374,417 ✅
    U+FFFD in stream 0 0 ✅
    (no commi─ / coatcha overlay 0 0 ✅ (legit text truncates as (no commit… │)
    UTF-8 validity valid valid ✅
    ESC[1A / ESC[2K 5927 / 6438 2583 / 2818 ✅
    ESC[?2026h/l sync pairs 500/500 224/224 ✅ balanced
    jsonl frames 503 228 ✅
    rendererCols != stdoutCols 0 0 ✅
    logicalLines > rendererRows 0 0 ✅
    max logicalLines 14 13 ✅

    Extra checks: #668 file-sink sanity — SEQUANT_DEBUG_RENDERER lines in terminal.typescript = 0/0 (post-#664 file sink confirmed active). Secret scan (sk-ant-/ghp_/github_pat_/AKIA/Bearer/api_key) — clean across all 4 capture files; safe to publish.

    CI Status

    build (22.x), typecheck, validate-skills, validate-plugin → SUCCESS. build (20.x) IN_PROGRESS — informational only: this is a .md/.jsonl/.typescript-only diff (no package.json/lockfile/tsconfig/config/workflow), so it cannot affect the build matrix, and build (22.x) already passed. Not gating (markdown-only CI relaxation).

    Review

    Strengths: Exemplary forensic rigor — every assertion is a reproducible byte/grep count, all verified with zero discrepancies. Correctly scoped: lands evidence + diagnosis, defers robustness work to #672, does not prematurely close #655. The "environmental, not a code bug" conclusion is appropriately hedged with an explicit pending cold-restart confirming test.

    Minor (non-blocking, being addressed): notes.md omitted a few #668 metadata-table fields (UTC, sequant --version, wall-clock, wc -l) — added in a follow-up commit. AC-3's literal "after 3 attempts" superseded by a definitive byte-level cause identification.

    Risk Assessment

    • Likely failure mode: None in-repo (inert data/docs). Interpretive risk — treating "environmental" as final before the cold-restart confirming test runs; notes.md guards against this explicitly.
    • Sibling sites: N/A — docs/data PR, no code call sites.

    Verdict: READY_FOR_MERGE

    All applicable ACs MET; conditional AC-2 correctly N/A; every diagnostic claim independently reproduces; bytes are secret-free. Only pending CI check is an informational redundant build-matrix entry on a docs-only diff.

    Next: After merge, run the pending cold-restart-VS-Code confirming test → close #655 as environmental or reopen; track robustness via #672.

  4. added
    ready-for-review
    on May 30, 2026
  5. added 2 commits that reference this issue on May 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    clihuman-requiredready-for-reviewui

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions