FR: Continue from last session

Resolved 💬 6 comments Opened Aug 28, 2025 by dlukt Closed Oct 19, 2025
💡 Likely answer: A maintainer (tibo-openai, collaborator) responded on this thread — see the highlighted reply below.

What feature would you like to see?

You start a project, codex works on it, you have context.
Then you go to bed, shutdown the computer, ending the current session.
You start a new session, all context is lost.
You have to have a NEXT.md, github issues and milestones etc, it needs to scan those and you waste tokens on this.

I propose a "continue from last session" feature.
Save state on exit for this codebase, and load state when starting in this codebase.
Optionally starting from 0 again (current status quo).

Are you interested in implementing this feature?

No

Additional information

All has been said

View original on GitHub ↗

6 Comments

deksden · 11 months ago

already implemented with codex --resume

should be marked as resolved?

dlukt · 11 months ago

Kind of but not exactly.
I guess it's good enough right now.
It's a new addition, I have to see how well it works.

--ask-for-approval                          -- Configure when the model requires human approval before executing a command
--cd                                        -- Tell the agent to use the specified directory as its working root
--config                                    -- Override a configuration value that would otherwise be loaded from `~/.codex/config.toml`. Use a dotted path (`fo
--continue                                  -- Continue the most recent conversation without showing the picker
--dangerously-bypass-approvals-and-sandbox  -- Skip all confirmation prompts and execute commands without sandboxing. EXTREMELY DANGEROUS. Intended solely for r
--full-auto                                 -- Convenience alias for low-friction sandboxed automatic execution (-a on-failure, --sandbox workspace-write)
--help                                      -- Print help (see more with '--help')
--image                                     -- Optional image(s) to attach to the initial prompt
--model                                     -- Model the agent should use
--oss                                       -- Convenience flag to select the local open source model provider. Equivalent to -c model_provider=oss; verifies a 
--profile                                   -- Configuration profile from config.toml to specify default options
--resume                                    -- Open an interactive picker to resume a previous session recorded on disk instead of starting a new one
--sandbox                                   -- Select the sandbox policy to use when executing model-generated shell commands
--search                                    -- Enable web search (off by default). When enabled, the native Responses `web_search` tool is available to the mode
--version                                   -- Print version
dlukt · 11 months ago

I used --continue
It's as if it was lobotomized.
Instead of doing the whole add, edit, generate, build, test cycle it just delegated all those to me.
It left the codebase in a broken state.

Also when it continued, 100% context left, then after 1 query it has 29% left.

deksden · 11 months ago
Also when it continued, 100% context left, then after 1 query it has 29% left.

"Continue" does not clear context, it's resuming session. "100% context left" is wrong indication, visual bug.

tibo-openai collaborator · 10 months ago

This is now supported with codex resume. Thanks for filing the issue!

snailwei · 1 month ago

codex resume is too long, not short as claude -c