Embedded terminal duplicates/stales characters when switching from Chinese Pinyin IME to English via Caps Lock on macOS

Open 💬 0 comments Opened May 12, 2026 by ichewm

What version of the Codex App are you using (From “About Codex” dialog)?

26.506.31421 (2620)

What subscription do you have?

plus

What platform is your computer?

macOS 26.3.1 (a) (25D771280a)

What issue are you seeing?

This issue occurs in the Codex App embedded terminal (the built-in terminal inside Codex), not macOS Terminal or iTerm.

When typing using the macOS Chinese Pinyin IME and switching to English input via Caps Lock during IME composition, the terminal visually renders duplicated/stale characters.

Example flow:

  1. Switch to Chinese Pinyin input
  2. Start typing in composition mode (example: gi)
  3. Before confirming the composition, press Caps Lock to switch to English input
  4. Continue typing

The terminal may visually render corrupted/duplicated text such as:

g igi

Expected input:

git

This appears to be a rendering/input-state issue in the embedded terminal. The command may still execute correctly, but the displayed text becomes incorrect.

What steps can reproduce the bug?

  1. Open Codex App
  1. Open any project
  1. Open the embedded terminal inside Codex
  1. Switch macOS input method to Chinese Pinyin IME
  1. Start typing in Chinese composition mode

Example:

gi

Do not confirm the IME composition.

  1. Press Caps Lock to switch to English input
  1. Continue typing

Example:

t

Result

Instead of rendering:

git

the terminal may display duplicated/corrupted text such as:

g igi

Notes

  • Reproducible consistently
  • Happens only in the Codex embedded terminal
  • Does NOT reproduce in macOS Terminal or iTerm
  • Seems related to IME composition + Caps Lock switching

What is the expected behavior?

The embedded terminal should correctly handle macOS Chinese IME composition.

Switching from Chinese Pinyin input to English using Caps Lock during composition should not duplicate characters or corrupt the terminal input state.

Expected:

git

instead of duplicated/corrupted output like:

g igi

Additional information

Environment:

  • Codex App: 26.506.31421 (2620)
  • macOS: 26.3.1 (a) (25D771280a)
  • Device: Mac mini
  • Input Method: macOS built-in Chinese Pinyin IME

This issue appears to affect the embedded terminal only.

I suspect this may be related to terminal rendering, IME composition handling, or Caps Lock language switching behavior.

View original on GitHub ↗