codex icon indicating copy to clipboard operation
codex copied to clipboard

VS Code Remote-SSH: Codex extension stuck on “Thinking”

Open MstarLioning opened this issue 1 year ago • 27 comments

What version of the VS Code extension are you using?

0.4.0

Which IDE are you using?

VS Code

What platform is your computer?

ssh Linux and local windows

What steps can reproduce the bug?

Hi everyone—looking for help! I’m using VS Code to connect to a remote server over SSH. I also set up reverse port forwarding to my local proxy so the remote terminal can access the internet. From the terminal on the server, both Claude Code and Codex work fine.

However, after installing the Codex extension in VS Code, no matter what I type it just stays on “Thinking” and eventually throws:

error sending request for url (https://chatgpt.com/backend-api/codex/responses)

ChatGPT suggested adding this to settings.json:

"remote.extensionKind": { "openai.chatgpt": ["ui"] }

If I do that, the Codex panel can produce responses, but it can’t read any files on the server—every path is shown as C:/xxx, as if the extension is running locally instead of on the remote host.

How can I fix this so the extension works and can access files on the remote server? Any advice would be greatly appreciated!

What is the expected behavior?

No response

What do you see instead?

No response

Additional information

No response

MstarLioning avatar Aug 31 '25 11:08 MstarLioning

same issue, different from the local running case is this: Image

FireFoxzzzz avatar Sep 05 '25 02:09 FireFoxzzzz

@FireFoxzzzz 试试终端跑吧,终端没问题,vscode里下载的codex不行,对于ssh远程连接的

MstarLioning avatar Sep 05 '25 07:09 MstarLioning

@FireFoxzzzz 试试终端跑吧,终端没问题,vscode里下载的codex不行,对于ssh远程连接的

同终端可以,codex插件不行。这个无法解决吗? @fouad-openai

Saunak626 avatar Sep 08 '25 15:09 Saunak626

I come across the same question, I can run the codex in the terminal but not in vsocde extensions.

efengshan avatar Sep 17 '25 05:09 efengshan

请问一下您最终解决了这个问题了吗

efengshan avatar Sep 18 '25 00:09 efengshan

请问一下您最终解决了这个问题了吗

https://github.com/openai/codex/issues/2796

应该是没有解决

Saunak626 avatar Sep 18 '25 00:09 Saunak626

请问一下您最终解决了这个问题了吗

#2796

应该是没有解决

好的好的,谢谢您。如果有决解也告知一下哈 感谢

efengshan avatar Sep 18 '25 00:09 efengshan

最新版测试是可以的

标识符 openai.chatgpt 版本 0.5.11 上次更新时间 2025-09-18, 09:23:01

FireFoxzzzz avatar Sep 18 '25 01:09 FireFoxzzzz

欸,这里的最新的不是0.4.10吗

efengshan avatar Sep 18 '25 01:09 efengshan

欸,这里的最新的不是0.4.10吗

预发布版本

FireFoxzzzz avatar Sep 18 '25 01:09 FireFoxzzzz

请问一下您最终解决了这个问题了吗

#2796 应该是没有解决

好的好的,谢谢您。如果有决解也告知一下哈 感谢

We changed some gateway settings. Can you let me know if the issue still persists?

我最新测试了一下codex 插件是可以使用ssh代理了

Saunak626 avatar Sep 18 '25 01:09 Saunak626

我试了一下从market place 下载的0.5.11版本 还是不行

efengshan avatar Sep 18 '25 04:09 efengshan

请问一下您最终解决了这个问题了吗

#2796 应该是没有解决

好的好的,谢谢您。如果有决解也告知一下哈 感谢

We changed some gateway settings. Can you let me know if the issue still persists?

我最新测试了一下codex 插件是可以使用ssh代理了

请问如何使用代理啊?

LucasGY avatar Sep 18 '25 09:09 LucasGY

奇怪,我更新到0.5.12还是不行,但是我的terminal中一直都是可以用的。

efengshan avatar Sep 19 '25 09:09 efengshan

我遇到的问题是 macOS 上的 GPT 客户端无法正常与通过 Remote-SSH 连接的 Linux 上的 VS Code 协作: 远程终端中运行 Codex 正常,本地 VS Code 与 GPT 的协作也正常,但 GPT 客户端无法读取远程文件,也无法正确与远程 VS Code 交互。 测试后发现,将远程 VS Code 上的 Codex 扩展回滚可以恢复功能。

Image I encountered an issue where the GPT client on macOS cannot properly collaborate with VS Code over Remote-SSH to a Linux server. Codex in the remote terminal works fine, and local VS Code + GPT collaboration also works, but the GPT client cannot read files or interact correctly with the remote VS Code session. After testing, rolling back the Codex extension on the remote VS Code helped restore functionality.

guanshantingbai avatar Sep 19 '25 22:09 guanshantingbai

@FireFoxzzzz 试试终端跑吧,终端没问题,vscode里下载的codex不行,对于ssh远程连接的

https://github.com/MikeJackOne/codex-vscode-remote-dev/blob/main/README.md

参考这个配置哦

MikeJackOne avatar Oct 14 '25 16:10 MikeJackOne

我遇到的问题是 macOS 上的 GPT 客户端无法正常与通过 Remote-SSH 连接的 Linux 上的 VS Code 协作: 远程终端中运行 Codex 正常,本地 VS Code 与 GPT 的协作也正常,但 GPT 客户端无法读取远程文件,也无法正确与远程 VS Code 交互。 测试后发现,将远程 VS Code 上的 Codex 扩展回滚可以恢复功能。

Image I encountered an issue where the GPT client on macOS cannot properly collaborate with VS Code over Remote-SSH to a Linux server. Codex in the remote terminal works fine, and local VS Code + GPT collaboration also works, but the GPT client cannot read files or interact correctly with the remote VS Code session. After testing, rolling back the Codex extension on the remote VS Code helped restore functionality.

https://github.com/MikeJackOne/codex-vscode-remote-dev/blob/main/README.md

参考这个配置哦

MikeJackOne avatar Oct 14 '25 16:10 MikeJackOne

本人已经解决该问题了,需要咨询的加微信:thisiseasytosearch,或者参考文档 https://github.com/MikeJackOne/codex-vscode-remote-dev/blob/main/README.md

MikeJackOne avatar Oct 14 '25 16:10 MikeJackOne

可以移除掉这个环境变量试试 NODE_OPTIONS=--openssl-legacy-provider,这也是为什么命令行可以,而插件不行的原因之一

microzbz avatar Oct 21 '25 07:10 microzbz

可以移除掉这个环境变量试试 NODE_OPTIONS=--openssl-legacy-provider,这也是为什么命令行可以,而插件不行的原因之一

为什么我没有找到这个环境变量

efengshan avatar Oct 21 '25 08:10 efengshan