codex - 💡(How to fix) Fix Codex Desktop on Windows repeatedly launches IntelliJ IDEA from project path click and triggers JetBrains DirectoryLock error

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

Codex launches idea64.exe again and IntelliJ IDEA shows an internal error: Repeatedly clicking the project directory address in Codex causes a scary IntelliJ internal error and makes the Codex directory link unreliable when IntelliJ is selected as the open target.

RAW_BUFFERClick to expand / collapse

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

26.513.40821

What subscription do you have?

pro

What platform is your computer?

No response

What issue are you seeing?

Environment:

  • OS: Windows
  • Codex Desktop: 26.513.40821
  • Codex CLI/runtime: 0.131.0-alpha.9
  • IntelliJ IDEA: 2025.3
  • IDEA path: D:\IntelliJ IDEA 2025.3\bin\idea64.exe
  • Project path: D:\workspace\xuanwu-contract-sign

Steps to reproduce:

  1. Open Codex Desktop on Windows.
  2. Configure/open target for the project path to IntelliJ IDEA.
  3. Click the project directory/path address in Codex.
  4. IDEA opens successfully if it is not already running.
  5. Click the same project directory/path address again while IDEA is already running.

Actual result: Codex launches idea64.exe again and IntelliJ IDEA shows an internal error:

com.intellij.platform.ide.bootstrap.DirectoryLock$CannotActivateException: Process "D:\IntelliJ IDEA 2025.3\bin\idea64.exe" is still running and does not respond.

Suppressed exceptions include: java.net.SocketException: Invalid argument: bind java.net.SocketException: Invalid argument: connect

Expected result: If IntelliJ IDEA is already running for that project, Codex should either:

  • activate/focus the existing IDEA window,
  • use JetBrains Toolbox/IDE protocol safely,
  • or avoid launching a second IDEA process from the project path click.

Additional findings:

  • The IDEA process is alive and responding.
  • Running Start-Process "D:\IntelliJ IDEA 2025.3\bin\idea64.exe" "D:\workspace\xuanwu-contract-sign" twice from PowerShell did not reproduce the issue.
  • Simulating Node spawn with the same executable/path also worked.
  • The issue appears specific to Codex Desktop's project path click/open-target flow or persisted open target state.
  • Codex persisted state contains: "open-in-target-preferences": {"global":"intellij","perPath":{"D:\workspace\xuanwu-contract-sign":"intellij"}}
  • Changing the persisted JSON to fileManager can be overwritten by the running Codex app on exit/restart.

Impact: Repeatedly clicking the project directory address in Codex causes a scary IntelliJ internal error and makes the Codex directory link unreliable when IntelliJ is selected as the open target.

What steps can reproduce the bug?

Codex Windows 客户端点击项目目录地址会重复启动 IDEA,而不是激活已有 IDEA,导致 IDEA 2025.3 报 DirectoryLock$CannotActivateException。这是 Codex 打开目标逻辑和 JetBrains 单实例机制的兼容问题。

What is the expected behavior?

No response

Additional information

No response

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING