PR text autogeneration fills in unrelated text from previous session

Resolved 💬 4 comments Opened Mar 27, 2026 by inb4ohnoes Closed Jun 22, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor) responded on this thread — see the highlighted reply below.

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

26.325.21211 (1255)

What subscription do you have?

Plus

What platform is your computer?

Darwin 25.4.0 arm64 arm

What issue are you seeing?

When clicking the "Create PR" button and leaving all fields blank to let Codex auto-generate a PR, the information generated is about a previous, archived session, not the current session. This seems to only happen sometimes so it's hard to reproduce reliably.

What steps can reproduce the bug?

  • Work in a session
  • Archive the session
  • Start new session
  • Work in new session
  • Create new branch, commit, push via top right button
  • Create PR via top right button, leave Title and detail fields blank to autogenerate
  • Resulting title and details are about the previous session, not the current session.

What is the expected behavior?

The autogenerated PR details pertain to current session

Additional information

This doesn't seem to happen with the commit messages if I leave them blank, only when creating a PR.

View original on GitHub ↗

4 Comments

github-actions[bot] contributor · 5 months ago

Potential duplicates detected. Please review them and close your issue if it is a duplicate.

  • #14971

Powered by Codex Action

inb4ohnoes · 5 months ago
Potential duplicates detected. Please review them and close your issue if it is a duplicate.

Not a duplicate

raye-deng · 5 months ago

This is a specific instance of a broader pattern we've been tracking: context leakage between AI sessions.

When an AI tool carries state from a previous session into a new one, the user gets outputs that look plausible (they reference real code, real patterns) but are factually wrong for the current context. The danger is that it's harder to spot than a completely fabricated response — because parts of it are correct, just from the wrong context.

We see three related failure modes in CI pipelines:

  1. Stale import references — AI generates imports based on a previous project state where a package existed, but it was removed in the current session. Code compiles if a stale node_modules is cached.
  1. Cross-session type drift — AI infers types from the previous session's context, then generates code that's type-compatible with those inferred types but incompatible with the actual current codebase state.
  1. Ghost CI artifacts — AI references test files, config entries, or environment variables from a previous run that no longer exist, but the CI pipeline has cached the old artifacts.

The root cause is the same: no boundary verification between sessions. The AI doesn't validate that its context assumptions match the actual current state before generating output.

We added session-boundary checks to our CI scanner that validate all external references (imports, API endpoints, config keys) against the current state, not just syntax correctness. It catches these stale-reference bugs that only manifest after session switches.

npx @opencodereview/cli scan . --sla L1
inb4ohnoes · 5 months ago

@raye-deng using ChatGPT to generate an advertisement for a competing product in OpenAI's own issue tracker is crazy. Not only does it derail the bug report, it also reflects poorly on your company's product and ethics...