Skip to content

fix(tui): remove 'q' alias from /quit, add to /queue#14681

Closed
8bit64k wants to merge 1 commit into
NousResearch:mainfrom
8bit64k:fix/tui-queue-alias
Closed

fix(tui): remove 'q' alias from /quit, add to /queue#14681
8bit64k wants to merge 1 commit into
NousResearch:mainfrom
8bit64k:fix/tui-queue-alias

Conversation

@8bit64k

@8bit64k 8bit64k commented Apr 23, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes the TUI frontend slash command registry where /q was incorrectly resolving to /quit instead of /queue.

Problem

PR #10538 fixed the Python backend (hermes_cli/commands.py) by removing 'q' from /quit's aliases, but the same bug persisted in the TUI TypeScript registry (ui-tui/src/app/slash/commands/core.ts).

The TUI's flat command lookup silently overwrote /queue's q alias with /quit's, making the documented /q shorthand for queueing prompts unusable — it always exited instead.

Changes

  • core.ts: Remove 'q' from /quit's aliases (keeps 'exit')
  • core.ts: Add aliases: ['q'] to /queue command

Related

Verification

  • /q <msg> now correctly queues a message
  • /quit and /exit still exit the TUI

The TUI frontend's slash command registry shadowed /queue's 'q' alias
with /quit's 'q' alias. Since /quit appeared later in the registry,
the flat lookup kept the later entry, making /q always quit instead
of queueing a prompt.

This mirrors the backend fix in PR NousResearch#10538 (hermes_cli/commands.py)
but applies the same correction to the TUI TypeScript registry.

Fixes NousResearch#10467
@alt-glitch alt-glitch added type/bug Something isn't working P2 Medium — degraded but workaround exists comp/tui Terminal UI (ui-tui/ + tui_gateway/) labels Apr 23, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Follow-up to merged #10538 (backend fix) — this PR fixes the same /q alias conflict in the TUI TypeScript registry. PRs #9830 and #7399 may be stale duplicates targeting the same issue.

@8bit64k

8bit64k commented Apr 25, 2026

Copy link
Copy Markdown
Contributor Author

Hey team — while reviewing the docs tonight I came across this note in the Slash Commands Reference:

"/queue (alias: /q) ... Note: /q is claimed by both /queue and /quit; the last registration wins, so /q resolves to /quit in practice. Use /queue explicitly."

This made me pause. If the collision is a known behavior that you've deliberately chosen to document rather than fix, I'm happy to close this PR — I don't want to push a change that runs counter to the project's intent. My assumption was that because /q is listed as an alias for /queue in the docs, the silent resolution to /quit was an oversight rather than a design choice.

How would you like /q to behave long-term? If the preference is for /quit to keep /q and for /queue to drop the alias from docs, I can adjust or withdraw. Just want to make sure whatever lands is what you actually want, not what I assumed.

@zoidypuh

Copy link
Copy Markdown

I think this PR is still correct. #10538 already resolved the same alias collision in the Python command registry by making /q
belong to /queue, while /quit keeps /exit.

The docs note appears stale now: it describes the old registry collision, but current hermes_cli/commands.py no longer gives /quit the q alias. The remaining bug is only in the Ink TUI local registry, where /quit still claims q.

So I’d treat this as a TUI parity fix, not a behavior change against docs. The docs should be updated to remove the warning once this lands.

@daimon-nous

daimon-nous Bot commented May 25, 2026

Copy link
Copy Markdown
Contributor

Merged via PR #32074 — your commit was cherry-picked onto current main with your authorship preserved in git log. Also included a regression test adapted from @hclsys's PR #31985. Thanks @8bit64k!

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/) P2 Medium — degraded but workaround exists type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug: /queue alias q is shadowed by /quit in command registry

3 participants