Remote SSH connection fail if remote default shell use fish

Open 💬 2 comments Opened Apr 16, 2026 by Clouder0

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

Version 26.415.20818 (1727)

What subscription do you have?

ChatGPT Pro

What platform is your computer?

Darwin 24.6.0 arm64 arm

What issue are you seeing?

When trying to connect to a remote machine with fish set as default shell, it would error out.

<img width="411" height="179" alt="Image" src="https://github.com/user-attachments/assets/c64ffc7b-18e6-4608-b1ef-008d4c2fe5d8" />

ish: Missing end to balance this if statement
if command -v codex >/dev/null 2>&1; then exit 0; fi; exit 86
^^

Setting remote shell to bash again, works.

Local Shell is still fish, does not affect. Only remote destination's shell setting to fish would lead to such error.

Local macOS, Remote Linux.

What steps can reproduce the bug?

Set default shell to fish on remote machine:

chsh -s /usr/bin/fish $USER

Open Codex App, try to connect, then fail.

What is the expected behavior?

_No response_

Additional information

_No response_

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗