Plan mode fails exact replacement of security redaction placeholder block and still reports ready to implement

Resolved 💬 2 comments Opened Apr 18, 2026 by LiableAvenger Closed Apr 18, 2026

What version of Codex CLI is running?

OpenAI Codex CLI v0.121.0, /collab (experimental)

What subscription do you have?

ChatGPT Pro

Which model were you using?

gpt-5.4 medium

What platform is your computer?

Microsoft Windows 11 Home, 10.0.26200, x64, AMD Ryzen 9 7900X

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

Standard Windows PowerShell console, un-elevated, PSVersion 5.1.26100.8115

What issue are you seeing?

In /collab plan mode, Codex repeatedly failed to apply an exact requested text replacement in a security-critical redaction block.

I asked Codex to regenerate the full plan and make one exact correction only: replace the entire placeholder list under ## Redaction rules with a specified list of required redaction placeholders, while preserving the rest of the plan. Across multiple planning passes, it continued omitting required placeholders such as <REDACTED OPENAI KEY>, <REDACTED ACTION API TOKEN>, and <REDACTED RUNTIME SECRET VALUE>, and still returned ready to implement: yes even though the acceptance criteria were not met. Earlier in the same sequence it also produced duplicate plan output.

This caused repeated manual review loops, unnecessary token usage, and reduced confidence in plan-mode acceptance checks for security-sensitive tasks.

What steps can reproduce the bug?

Uploaded thread: 019da170-ef19-7600-a872-ab56a23ead71

  1. Start Codex CLI in /collab or plan mode using gpt-5.4 medium.
  1. Ask it to generate a long structured plan containing sections such as:
  • ## Redaction rules
  • Manifest must include
  • ## Final return shape
  1. Ask Codex to regenerate the full plan from top to bottom and make one exact correction only:
  • replace the entire placeholder list under ## Redaction rules
  • preserve the rest of the plan unchanged
  • keep manifest path at item 9 in the final return shape
  • keep the manifest block intact
  • only return ready to implement: yes if the returned full plan visibly contains every required placeholder
  1. Use a prompt like this:

_______________________________________
The plan is still not ready to execute.

Regenerate the FULL plan from top to bottom.
Do not shorten it.
Do not summarize it.
Do not omit sections.
Do not weaken any already-approved scope.

Mandatory correction:
Under:

Redaction rules

Use stable placeholders such as:

replace the entire placeholder list with this exact list, verbatim and in this order:

  • <REDACTED DISCORD TOKEN>
  • <REDACTED OPENAI KEY>
  • <REDACTED ACTION API TOKEN>
  • <REDACTED OWNER SESSION SECRET>
  • <REDACTED OWNER TOTP SECRET>
  • <REDACTED TRUSTED LOGIN SECRET>
  • <REDACTED RUNTIME SECRET VALUE>
  • <REDACTED USER CONTENT>
  • <REDACTED THIRD-PARTY SENSITIVE DATA>

Required verification inside the regenerated full plan:

  1. The "Manifest must include:" block must still contain exactly:
  • original file path
  • staged snapshot path
  • reason included
  • redaction applied yes/no
  • excerpt created yes/no
  • structure excerpt created yes/no
  1. The "## Final return shape" section must still include:
  2. manifest path
  1. The "## Redaction rules" section must still explicitly state that these categories are redacted:
  • API keys
  • bearer secrets
  • TOTP secrets
  • runtime secret values

Only answer "ready to implement: yes" if every placeholder above is visibly present in the returned full plan, the manifest block still includes structure excerpt created yes/no, and final return shape item 9 is manifest path.

_______________________________________

  1. Observe that Codex may:
  • return the full plan, but only partially apply the placeholder replacement
  • omit some required placeholders
  • regress previously present placeholders
  • and still report ready to implement: yes
  1. In my case, earlier in the same planning sequence, Codex also produced duplicate full plan output before the later partial-correction behavior.

What is the expected behavior?

Codex should apply the exact requested replacement to the placeholder block, preserve the rest of the approved plan unchanged, and only report ready to implement: yes when all required placeholders and acceptance criteria are visibly present in the returned full plan.

It should not:

  • partially apply the requested replacement
  • drop or regress previously present placeholders
  • produce duplicate full plan outputs for the same pass
  • or mark the plan ready when required security redactions are still missing

Additional information

  • This happened in the standard Windows PowerShell console, not an elevated shell.
  • The project path was opened from the project root in PowerShell.
  • The issue appeared across multiple planning passes in the same session.
  • The failure involved a security-sensitive redaction block for secret placeholders.
  • In the latest returned plan, Codex included <REDACTED OWNER TOTP SECRET> but still omitted <REDACTED OPENAI KEY>, <REDACTED ACTION API TOKEN>, and <REDACTED RUNTIME SECRET VALUE>, while still reporting ready to implement: yes.
  • The manifest section remained intact, which suggests partial compliance rather than total prompt failure.
  • I can provide a sanitized transcript if needed.

View original on GitHub ↗

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