Vscode extension: Add a folder to your workspace to use Codex
Resolved 💬 22 comments Opened Nov 19, 2025 by wiegell Closed Dec 4, 2025
What version of Codex is running?
codex --version codex-cli 0.58.0, vscode extension v0.5.43
What subscription do you have?
Paid
Which model were you using?
GPT-5.1-medium
What platform is your computer?
MacOS
What issue are you seeing?
I get this error:
<img width="585" height="180" alt="Image" src="https://github.com/user-attachments/assets/3967134b-fae6-42fe-a0b4-3b54ea81eb12" />
What steps can reproduce the bug?
Atm. whenever i start a new chat like this it happends
<img width="613" height="118" alt="Image" src="https://github.com/user-attachments/assets/6cde8c40-0147-4fb5-a7b3-9f69d19a17d7" />
What is the expected behavior?
Should just work
Additional information
This is not happening, when prompting via the sidebar.
This has been happening for the last week or so
22 Comments
Same thing here
++
Me too. It happened from yesterday's new chat.
<img width="740" height="826" alt="Image" src="https://github.com/user-attachments/assets/2e551638-9928-4798-b7b7-507f4c1bb929" />
++
same problem
++ It happened right after I upgrade codex just now 👎
Bug Report: “New Codex Agent” (+ button) no longer creates agent sessions (regression in pre-release 0.5.46)
Summary
In OpenAI VS Code Extension (pre-release v0.5.46), the “+ New Codex Agent” button in the OpenAI Codex sidebar no longer creates a functional agent session.
This is a regression from behavior ~3 days ago, where the same button correctly spawned fully-functional local agent sessions.
Expected Behavior (previous pre-release versions)
Clicking the + button with tooltip “New Codex Agent” should:
This was functioning correctly earlier this week.
Actual Behavior (v0.5.46)
Clicking + New Codex Agent now:
Repro Steps
ps aux)Result:
A non-functional placeholder session appears in the session list.
No agent session is created.
No chat surface appears.
Codex panel shows fallback UI.
Expected:
A new agent session is created and fully interactive.
Other Information
OpenAI: Start Agent Session → works
Diagnosis
The + button is still bound to the old
chat.newcommand instead of the new agent session creation command (agent.newSession).Auto-promotion from Chat → Agent was removed, exposing the mismatch.
The UI label was updated, but not the command wiring.
Impact
Suggested Fix
``
``openai.agent.newSession
Same kind of issue.
Just updated to :
Identifier
openai.chatgpt
Version
0.4.46
Last Updated
2 hours ago
Size
71.69MB
Have a separate window on left-hand screen.
Codex opened as a tab in that separate window.
Type prompt.
"Unable to send message
Add a folder to your workspace to use Codex"
Same message for:
Have not tested with other combinations.
I've reopened the chat sidebar now to check, and I do get a normal response (e.g. asking 'are you there? : 'Yes, I’m here and ready to help. What would you like to work on in this project?')
I can't confirm if this was the same behaviour on the previous version of the extension (I think I was on 0.4.43 before updating today). I did not have separate windows for my chats, just used the sidebar.
Could you please guys try with official OpenAI Codex extension?
<img width="452" height="751" alt="Image" src="https://github.com/user-attachments/assets/f7ce830e-a21c-4d44-a148-34eac0cf9af9" />
There is no issue when using the official OpenAI extension. The problem is that I want to continue from my chat history, but since I cannot access my chat history in the official OpenAI extension, we have to start over every time. Since OpenAI chat history is available in agent sessions, everyone here is trying to continue their past chats, and that's why we are getting warnings.
i think you're in the wrong ticket, mate. no one else has mentioned chat history in this ticket before.
The root of the problem is the same. Yes, it can be run smoothly through a chat using the OpenAI extension, but when you close and reopen your work, you can’t continue from your chat history. If you want to continue from your chat history, you encounter the warning that is the subject of this ticket issue. I’m currently experiencing this problem myself.
I suspect you might not be looking at the correct view in VS Code, and you may not be aware that there are multiple AI tools available there.
There are three different tools involved:
---
The problem
When I try to start a Codex session in the Agent Session View, I get the error mentioned in this ticket.
However, if I start a chat using the official OpenAI Codex extension, everything works fine and I don’t get that error.
---
Possible confusion
I’m also suspicious that you might have forgotten to change the view / provider in either GitHub Copilot Chat or Agent Session.
You can switch it by clicking the three dots in the top-left corner of the chat panel and selecting the correct view (for example, switching between Chat (Github Copilot Chat) and Agent Sessions:
Thanks for clarifying the differences between the chat views.
I’m using the Agent Sessions option (from the sidebar) and can access my agent chat history, but whenever I select a previous chat to continue, I still get the “Add a folder to your workspace to use Codex” warning.
I’ve double-checked that all extensions and VS Code are up to date, and there is no provider selection just a switch between “Chat” and “Agent Sessions”.
Starting a new agent chat works fine, but resuming an old session always results in the same warning. Is there any workaround for this, or anything else I should try?
<img width="877" height="575" alt="Image" src="https://github.com/user-attachments/assets/0e0b6ae5-9100-484a-8c60-f0bdceda3cfd" />
I'm having same issue here. any fix ?
++
++
Did you try to continue your chat with Official OpenAI Codex extension? You might continue to your chat without issue with this extension. I think agent Sessions views is buggy at the moment.
<img width="600" height="178" alt="Image" src="https://github.com/user-attachments/assets/f0bd1763-e9fe-45cd-b04f-1b4e985fe680" />
Yes, I tried it. As you can see in the image, Codex cannot display past tasks.
<img width="516" height="968" alt="Image" src="https://github.com/user-attachments/assets/531d7ea5-66fa-4739-8cd5-069ec533b314" />
seems to be fixed on v0.5.48
To use Codex in VS Code, you need to have a folder opened as your workspace root (Codex can’t properly work if you only opened a single file)
So, File → Open Folder → pick your project folder (this becomes the workspace root)
And try it again, it should works
thanks!!!