TUI trust prompt hides config/batchWrite failure cause when setting project trust

Open 💬 3 comments Opened May 29, 2026 by mahendra202602

What version of Codex CLI is running?

codex-cli 0.135.0

What subscription do you have?

corporate

Which model were you using?

gpt-5.5

What platform is your computer?

Linux 5.15.0-316.196.4.1.el8uek.x86_64 x86_64 x86_64

What terminal emulator and version are you using (if applicable)?

macOS Terminal.app, SSH to Linux host

Codex doctor report

What issue are you seeing?

When starting Codex in an untrusted directory and selecting the option to
trust the directory, the TUI shows only:

Failed to set trust for <my_cwd_path>: config/batchWrite failed in TUI

This message is not actionable because it hides the underlying app-server/
config error. The failed operation is trying to persist project trust to the
user config, equivalent to:

[projects."<my_cwd_path>"]
trust_level = "trusted"

What steps can reproduce the bug?

  1. Start Codex in a directory that is not already trusted, for example:

cd <my_cwd_path>
codex

  1. At the TUI trust prompt, select the option to trust/continue.
  2. Observe the error:

Failed to set trust for <my_cwd_path>: config/batchWrite failed in TUI

What is the expected behavior?

The TUI should include the underlying config/batchWrite server error, for
example:

Failed to set trust for <my_cwd_path>: config/batchWrite failed in TUI:
<server-side cause>

or otherwise surface the JSON-RPC error message/data so the user can
distinguish readonly config, invalid config, app-server failure, and
validation failures.

Additional information

_No response_

View original on GitHub ↗

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