Skip to content

fix: QA rounds 3-6 — B58-B64 fixed, 10 tmux flows, promptable agent switching#33

Merged
e6qu merged 5 commits intodevfrom
qa/deeper-testing
Mar 22, 2026
Merged

fix: QA rounds 3-6 — B58-B64 fixed, 10 tmux flows, promptable agent switching#33
e6qu merged 5 commits intodevfrom
qa/deeper-testing

Conversation

@e6qu
Copy link
Copy Markdown
Owner

@e6qu e6qu commented Mar 22, 2026

Summary

Deep QA across 4 rounds (rounds 3-6), covering bug fixes, false positive verification, tmux visual testing, and feature documentation.

Bug fixes (7)

  • B58: pluginGuard() uncaught Plugin.trigger() errors — try-catch → EditResult error
  • B59: pluginNotify() silent Plugin.trigger() errors — try-catch → log.warn
  • B60: Objective markdown injection into system prompt — escaped newlines + markdown chars
  • B61: MCP add() inconsistent return type (Status vs Record) — all branches return Record
  • B62: Text part timing start overwritten at stream end — preserve original start time
  • B63: Unguarded JSON.parse on ripgrep output — flatMap with try-catch, log.warn
  • B64: Untracked file line count off-by-one — trimEnd() before split

Testing (10 tmux flows)

  • home, command-palette, agent-cycle, submit-message, cost-dialog
  • slash-command, multi-agent-verify (round 5)
  • slash-classify, slash-threads, slash-history (round 6)
  • All screenshots reviewed — clean rendering, no visual bugs
  • 1515 unit tests pass, 0 failures

False positives verified (49 total)

  • 23 from round 3, 18 from round 5, 5 from round 6 (+ 3 from round 4)
  • Categories: transaction safety, SQLite synchronicity, JS Map iteration, async fire-and-forget patterns, sweep/lifecycle design

Features

  • Promptable agent switching: documented in docs/agents.md — Build ↔ Plan via plan_enter/plan_exit tools
  • Autonomous switching: updated tool descriptions to enable proactive back-and-forth mode switching without user prompt
  • Integration proof tests for context editing (hide → filterEdited, unhide → restore, mark → sweep)
  • History editing prompts documented in docs/context-editing.md

Test plan

  • bun test --timeout 30000 — 1515 pass, 0 fail
  • bun test/cli/tui/tmux-tui-test.ts — 10 flows pass
  • npx tsgo --noEmit — 0 errors (packages/opencode)
  • All screenshots reviewed for visual issues

Adrian Mârza added 2 commits March 22, 2026 04:33
B58: pluginGuard() now catches Plugin.trigger() errors and returns
EditResult error instead of propagating uncaught exception.

B59: pluginNotify() now catches Plugin.trigger() errors and logs
warning instead of silently ignoring.

BUGS.md cleaned up:
- Removed duplicate "Open — Bugs (0)" section
- Added B58-B59 as fixed
- Added 10 new false positives from QA analysis (V1, R4, E1-fork,
  PM1, PM2, etc.) — each verified with reasoning
- Updated Q3 reference from "this PR" to "PR #31"
- Total: 0 open bugs, 64 fixed, 15 false positives documented
Third round of deep analysis covering: session management, compaction,
prompt pipeline, skill/scripts, command templates, truncation.

All areas clean. All previous fixes (B48, B38, B57) verified holding.

New false positives (5):
- updatePart() orphaned parts → FK constraint prevents
- Script paths with spaces → array-based execution is safe
- Truncation boundary at maxBytes → comparison is correct
- Compaction during prompt → BusyError prevents
- filterEdited + sweep same part → orthogonal concerns

Total: 0 open bugs, 20 verified false positives.
@e6qu e6qu changed the title fix: plugin hook error handling (B58-B59) + BUGS.md cleanup + false positive verification fix: B58-B59 plugin hooks + 3 rounds QA (0 open bugs, 20 false positives) Mar 22, 2026
…tion proof tests

B60 (Med): Objective text injected directly into system prompt markdown.
Newlines and markdown chars (backticks, headers) could break formatting.
Fix: escape newlines and markdown special chars before injection.

Sweep error logging: Database.transaction() in sweep() now wrapped in
try-catch with log.error() instead of silent failure.

Integration proof tests (3 new):
- PROOF: hide() removes content from LLM context, CAS preserves original
- PROOF: unhide() restores original content from CAS
- PROOF: mark discardable + sweep removes content after N turns

Each test creates a real session with messages, performs the edit operation,
then verifies the content IS present before and IS NOT present after
(or vice versa for unhide). CAS storage verified independently.

Cross-module false positives documented (3 new):
- Protected message window timing → benign race
- Side thread system prompt staleness → fresh DB query per prompt
- Sweep transaction failure → now logged

tmux TUI tests: all 5 flows pass including LLM submit-message and cost-dialog.
@e6qu e6qu changed the title fix: B58-B59 plugin hooks + 3 rounds QA (0 open bugs, 20 false positives) fix: 4 rounds QA — B58-B60 fixed, 3 proof tests, 23 false positives, tmux verified Mar 22, 2026
Adrian Mârza added 2 commits March 22, 2026 05:35
…uide

Added to docs/context-editing.md:
- Direct prompts to trigger context editing (hide, replace, externalize, mark, park)
- Complete slash command reference (/focus, /focus-rewrite-history, /btw, /reset-context, /classify, /threads, /history, /tree)
- How to enable focus agents in opencode.json config
- How history editing is verified (integration proof tests)
…witching

- B61: MCP add() inconsistent return type (Status vs Record) — all branches now return Record
- B62: text part timing start overwritten at stream end — preserve original start
- B63: unguarded JSON.parse on ripgrep output — flatMap with try-catch
- B64: untracked file line count off-by-one — trimEnd before split
- 5 new tmux test flows (slash-command, multi-agent-verify, slash-classify, slash-threads, slash-history) — 10 total
- Promptable agent mode switching: updated plan_enter/plan_exit tool descriptions for autonomous back-and-forth switching
- Documented mode switching flow in docs/agents.md
- 23 new false positives verified (49 total in BUGS.md)
@e6qu e6qu changed the title fix: 4 rounds QA — B58-B60 fixed, 3 proof tests, 23 false positives, tmux verified fix: QA rounds 3-6 — B58-B64 fixed, 10 tmux flows, promptable agent switching Mar 22, 2026
@e6qu e6qu merged commit 239d232 into dev Mar 22, 2026
1 check passed
@e6qu e6qu deleted the qa/deeper-testing branch March 22, 2026 04:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant