-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Open
Labels
bugSomething isn't workingSomething isn't working
Description
What version of Codex is running?
Latest version (0.53)
What subscription do you have?
ChatGPT Plus
Which model were you using?
GPT-5-Codex
What platform is your computer?
Windows 11 x64
What issue are you seeing?
Issue Description
When Codex CLI starts a long-running server process (e.g., development servers like npm run dev, langgraph gdev, Django runserver, etc.), the agent blocks indefinitely and waits for the server to terminate before continuing with any other tasks.
This creates a critical workflow blocker because:
- The agent cannot continue - It sits idle showing "Working 10s...", "Working 20s..." etc., without performing any other operations
-
- Requires manual intervention - Users must repeatedly stop the agent (Ctrl+C) and restart it to continue development
-
- Breaks iterative workflow - Cannot ask the agent to start a server, then make code changes, then test the running server
-
- Affects all long-running processes - Any terminal command that doesn't exit (servers, watchers, monitoring tools) causes this behavior
Example Scenario
User asks: "Start the development server, then make changes to the API endpoints"
What happens:
- Codex runs
npm run devorlanggraph dev --port 8123 -
- Server starts successfully and runs in foreground
-
-
- Agent shows "Working 30s...", "Working 60s...", etc.
-
-
-
-
- Agent never proceeds to make the requested code changes
-
-
-
-
-
-
- User must kill Codex, restart it, manually keep server running in separate terminal, then ask again
This makes Codex unusable for typical development workflows where servers run continuously while development happens.
- User must kill Codex, restart it, manually keep server running in separate terminal, then ask again
-
-
-
What steps can reproduce the bug?
Reproduction Steps
Method 1: Simple Test with Python HTTP Server
- Open terminal and navigate to any directory
-
- Run
codex
- Run
-
- Give prompt: "Start a Python HTTP server on port 8000, then create a new test.html file"
-
- Codex executes:
python -m http.server 8000
- Codex executes:
-
- Server starts and runs indefinitely
-
- Observe: Agent shows "Working 10s...", "Working 30s...", "Working 60s..." etc.
-
- Observe: Agent NEVER proceeds to create test.html
-
- Must manually kill the agent with Ctrl+C
Method 2: Development Server (LangGraph example)
- In a LangGraph project directory
-
- Run
codex
- Run
-
- Give prompt: "Start the LangGraph dev server, then update the agent configuration in langgraph.json"
-
- Codex executes:
langgraph dev --port 8123
- Codex executes:
-
- Server starts successfully and displays ready message
-
- Observe: Agent blocks indefinitely on the running server
-
- Observe: Never proceeds to edit langgraph.json
-
- Must kill and restart agent to continue
Method 3: NPM Development Server
- In a Node.js/React project
-
- Run
codex
- Run
-
- Give prompt: "Start the dev server and then fix the typo in App.js"
-
- Codex executes:
npm run dev
- Codex executes:
-
- Dev server starts and shows "Compiled successfully"
-
- Observe: Agent waits indefinitely for npm process to exit
-
- Never proceeds to edit App.js
Affected Commands
Any long-running terminal process causes this:
npm run dev/npm start-
python -m http.server
-
-
langgraph dev
-
-
-
-
flask run
-
-
-
-
-
-
django-admin runserver
-
-
-
-
-
-
-
-
nodemon
-
-
-
-
-
-
-
-
-
-
- Watch commands (
npm run watch,tsc --watch)
- Watch commands (
-
-
-
-
-
-
-
-
-
-
-
-
- Monitoring tools
-
-
-
-
-
-
What is the expected behavior?
No response
Additional information
No response
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working