Skip to content

fix(tui): ignore empty key sequences#28014

Open
mturac wants to merge 1 commit into
anomalyco:devfrom
mturac:fix/28007-empty-key-sequence
Open

fix(tui): ignore empty key sequences#28014
mturac wants to merge 1 commit into
anomalyco:devfrom
mturac:fix/28007-empty-key-sequence

Conversation

@mturac
Copy link
Copy Markdown

@mturac mturac commented May 17, 2026

Issue for this PR

Closes #28007

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

Guards TUI key sequence formatting so missing or empty command bindings render as an empty shortcut label instead of calling OpenTUI's formatter with an empty sequence. This prevents startup/render crashes when a command has no registered binding.

How did you verify your code works?

  • bun test test/cli/tui/keymap.test.ts --timeout 30000
  • bun typecheck
  • bunx prettier --check src/cli/cmd/tui/keymap.tsx test/cli/tui/keymap.test.ts
  • git diff --check
  • git push -u mturac fix/28007-empty-key-sequence (pre-push bun turbo typecheck)

Screenshots / recordings

Not applicable; this is a TUI key formatting guard covered by a regression test.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

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.

opentui: fatal: Invalid key sequence: sequence cannot be empty

1 participant