Service eligibility and regional restrictions
PuppyIP serves only compliant overseas businesses and their authorized personnel. Proxy services are not available in mainland China. The service may only be used for lawful business activities outside mainland China. Use of this service within mainland China is prohibited.
Hosting a proxy IP or server overseas does not change these restrictions. The service must not be provided to end users in mainland China through relaying, forwarding, sharing or resale. Before use, read the Terms of Service.
Key Takeaways
- Check the directory where your script starts and the directory where the resumed session runs separately.
- Use a saved session ID to select a specific run. When you use --last, your current directory controls the default search scope.
- On the first resumed turn, check the paths and existing changes before you continue writing.
What does this release restore?
The working directory is where commands run. Workspace roots describe the working scope stored for the session. Sandbox permissions govern what commands can do. Version 0.172.0 restores all three saved settings for non-interactive codex exec resume. Explicit overrides still apply.
Suppose you started a task in a worktree for repository A and then resumed its saved session ID from directory B. Without an explicit override, the saved paths and permissions apply. Check the actual directory and repository before continuing the edit.
How do you select the right saved session?
Run codex --version in the environment that actually executes the task. If you know the saved ID, run codex exec resume SESSION_ID and replace SESSION_ID with that value.
The CLI reference says --last looks for the most recent session in your current directory by default. Adding --all extends the search to other directories. After changing directories, an explicit ID avoids accidentally selecting the most recent task in a different project.
How do you confirm where the script resumed?
Start with a read-only follow-up that reports the effective working directory, Git repository root, and existing working-tree status. Compare the output with the original task record, especially when you use several branches or worktrees.
If a wrapper passes a directory or sandbox override, check the arguments it actually supplies, its configuration, and the CLI help. If the directory remains unavailable, see whether the original worktree moved or was removed before deciding where to start again.
How do the starting directory and workspace roots differ?
The directory you start from affects the default session search with --last. The restored working directory controls where commands run. Workspace roots describe the session's working scope. Check them individually when diagnosing a script.
What should a scheduled script log for its next resume?
Record the CLI version, session ID, expected working directory, and repository root when the task starts. If you use a worktree, record its path and branch too. Use these details to identify the task when a resume request arrives instead of relying on timestamps alone.
If the directory differs from what you expected, verify the selected session ID before checking the working directory and explicit options. If the directory matches but a write is denied, check the saved sandbox permissions and any overrides the wrapper applied. A repository can have several worktrees, so also compare the paths when the repository names match.
If the previous process stopped during a push, release, or another external operation, check the outcome of that operation first. Resume that step only after you confirm it is unfinished and still part of the task.
Sources
Frequently Asked Questions
Does this fix also apply to the Codex desktop app?
This release note specifically describes the non-interactive CLI command codex exec resume. The desktop app and interactive command have their own resume controls and release notes.
What if the original worktree was deleted before I resumed?
Confirm whether the original path and files are still present, then check any saved commits or worktree records. Resuming restores session context and settings. Recover deleted files through the original worktree recovery record or Git.