mirror of
https://github.com/openai/codex.git
synced 2026-09-06 15:29:32 +00:00
## Why The `cwd` recorded in a rollout can become stale after thread metadata is updated, causing thread reads and lists to disagree with the persisted state. ## What changed - Overlay a non-empty state database `cwd` when reading a thread by ID. - Apply the same overlay when reading by rollout path, but only when the metadata points to the requested rollout. - Recompute the permission profile against the selected `cwd` and continue to fall back to rollout metadata when the persisted `cwd` is empty or belongs to another rollout. ## Testing - Cover stale, empty, and mismatched persisted `cwd` metadata. - Verify that `thread/read`, state-only `thread/list`, and `thread/resume` report the persisted thread `cwd` while the resumed session uses its requested live `cwd`. GitOrigin-RevId: 50a3f187618ee3cadbad95196ee2976e2d5e9a5a