Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

tui: NumPad End/Home ignored under kitty keyboard protocol (Windows Terminal reports KP_END 57424)

Open Beginner friendly
#55,533 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@argszero is already working on this.

Since Oct 14, 2026.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
75/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
typescript
Domain
cli

Research direction

Start with the default keybind table for input.line.home and input.line.end and add the kphome and kpend names alongside home and end, as the workaround in cli.json does. Check that the kitty keyboard parser maps CSI 57424 u to kpend, since the issue says the names are already accepted. Done when NumPad End and Home trigger the same actions as the regular keys, and the other NumPad navigation keys are covered too.

Written by the indexing model from the issue text.

Description

reproduced
Description

NumPad End (NumLock off) does nothing in the TUI, while the regular End key works. Same for the other NumPad navigation keys.

With the kitty keyboard protocol enabled, Windows Terminal reports NumPad End as KP_END (CSI 57424 u) rather than End. OpenCode doesn't treat it as End, so the default end bindings never fire. Outside OpenCode both keys send ^[[F, so the terminal is fine.

Expected: NumPad navigation keys behave like their regular equivalents (kpend → end, kphome → home, and so on), the same way opentui#1047 handled NumPad digits and Enter in the textarea.

Workaround: adding the kp* names to cli.json works (after restarting the TUI), so the key names are already parsed and accepted. They just aren't in the defaults:

"keybinds": {
  "input.line.home": "ctrl+a,home,kphome",
  "input.line.end": "ctrl+e,end,kpend"
}

Earlier reports of the same root cause were auto-closed in V1: #20461, #7698.

Plugins

None related (one local personal plugin)

OpenCode version

2.0.29

Steps to reproduce
  1. In Windows Terminal (WSL), with NumLock off, run printf '\e[>1u'; cat -v; printf '\e[<u'
  2. Press End, then NumPad End. Output: ^[[F^[[57424u
  3. Open OpenCode with default keybinds, scroll up in a session, and press End: it jumps to the last message. Press NumPad End: nothing happens.
Screenshot and/or share link

N/A

Operating System

Windows 11 + WSL2, Ubuntu 26 (Linux 6.18.54.1-microsoft-standard-WSL2)

Terminal

Windows Terminal

Dominant language
TypeScript
Stars
213k
Forks
28.4k
Avg merge
8h 32m
Merged PRs (30d)
253

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from anomalyco/opencode

All issues in anomalyco/opencode

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.