Skip to content

fix(tui): keep /goal verdict out of compact status row#27971

Merged
austinpickett merged 1 commit into
mainfrom
austin/fix/goal-statusbar
May 18, 2026
Merged

fix(tui): keep /goal verdict out of compact status row#27971
austinpickett merged 1 commit into
mainfrom
austin/fix/goal-statusbar

Conversation

@austinpickett

@austinpickett austinpickett commented May 18, 2026

Copy link
Copy Markdown
Collaborator

What does this PR do?

When /goal finished, the gateway sent status.update with kind: "goal" and the full judge verdict as text. The handler applied setStatus(p.text) for every payload before branching on kind, so the status bar rendered that long sentence on the same row as model, context usage, and cwd — making it look like the verdict had “merged” with the status chrome.

This change handles kind === "goal" first: the full verdict still goes to the transcript via sys(), but the Nanostores status becomes a short label (✓ goal complete, ↻ goal continuing, ⏸ goal paused, or ready) and restores to idle after restoreStatusAfter(6000).

No server / Python changes — client-only.

Related Issue

N/A (no filed issue attached).

Fixes #(n/a — report was in chat)

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 🔒 Security fix
  • 📝 Documentation update
  • ✅ Tests (adding or improving test coverage)
  • ♻️ Refactor (no behavior change)
  • 🎯 New skill (bundled or hub)

Changes Made

  • ui-tui/src/app/createGatewayEventHandler.ts — process status.update payloads with kind: "goal" before the generic setStatus(p.text) path; narrow idle status labels; reuse existing restoreStatusAfter.
  • ui-tui/src/__tests__/createGatewayEventHandler.test.ts — Vitest assertions for transcript vs. brief UI status and prefix mapping.

How to Test

  1. Run cd ui-tui && npm test -- --run src/__tests__/createGatewayEventHandler.test.ts.
  2. Manually: hermes --tui, set a /goal …, complete a turn; confirm the verdict appears as a system line while the bottom status row stays short (model / usage / path), without the long verdict string inline.

Checklist

Code

  • I've read the Contributing Guide
  • My commit messages follow Conventional Commits (fix(scope):, feat(scope):, etc.)
  • I searched for existing PRs to make sure this isn't a duplicate
  • My PR contains only changes related to this fix/feature (no unrelated commits)
  • I've run pytest tests/ -q and all tests pass
  • I've added tests for my changes (required for bug fixes, strongly encouraged for features)
  • I've tested on my platform:

Documentation & Housekeeping

  • I've updated relevant documentation (README, docs/, docstrings) — or N/A
  • I've updated cli-config.yaml.example if I added/changed config keys — or N/A
  • I've updated CONTRIBUTING.md or AGENTS.md if I changed architecture or workflows — or N/A
  • I've considered cross-platform impact (Windows, macOS) per the compatibility guide — or N/A
  • I've updated tool descriptions/schemas if I changed tool behavior — or N/A

For New Skills

N/A.

Screenshots / Logs

image

Goal judge messages were routed through setStatus before the goal branch,
so the full verdict string shared one line with model/usage/cwd in StatusRule.

Handle kind goal first: append transcript via sys, show a short status, then
restore to ready after the normal delay. Adds Vitest coverage.

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions

Copy link
Copy Markdown
Contributor

🔎 Lint report: austin/fix/goal-statusbar vs origin/main

ruff

Total: 0 on HEAD, 0 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 0 pre-existing issues carried over.

ty (type checker)

Total: 8787 on HEAD, 8787 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 4617 pre-existing issues carried over.

Diagnostics are surfaced as warnings — this check never fails the build.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes the TUI gateway event handling so /goal verdicts remain visible in the transcript without overflowing the compact status row.

Changes:

  • Handles status.update events with kind: "goal" before the generic status path.
  • Maps full goal verdict text to short status labels and restores idle status after a delay.
  • Adds Vitest coverage for transcript output and goal status prefix mapping.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
ui-tui/src/app/createGatewayEventHandler.ts Special-cases goal status updates to emit transcript text while keeping the UI status short.
ui-tui/src/__tests__/createGatewayEventHandler.test.ts Adds tests for goal verdict transcript behavior and compact status labels.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@alt-glitch alt-glitch added type/bug Something isn't working comp/tui Terminal UI (ui-tui/ + tui_gateway/) P3 Low — cosmetic, nice to have labels May 18, 2026
@austinpickett austinpickett merged commit 609c485 into main May 18, 2026
14 of 15 checks passed
@austinpickett austinpickett deleted the austin/fix/goal-statusbar branch May 18, 2026 12:42
Lillard01 pushed a commit to Lillard01/hermes-agent that referenced this pull request May 21, 2026
…al-statusbar

fix(tui): keep /goal verdict out of compact status row
gweeteve pushed a commit to gweeteve/hermes-agent that referenced this pull request Jun 2, 2026
…al-statusbar

fix(tui): keep /goal verdict out of compact status row
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/tui Terminal UI (ui-tui/ + tui_gateway/) P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants