mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:31:09 +00:00
Revert the current thread when editing an earlier TUI prompt (#45845)
## What changed Use `thread/revert` to remove the selected turn and subsequent history, then restore the selected prompt in the composer. Keep the thread identity, settings, goal, and unrelated thread channels intact. Show a notice that conversation history was reverted and file changes are unchanged. Resolve selections against persisted history, accounting for partially loaded transcripts and hidden review prompts. Reject stale selections and mid-turn steers. Refresh replay state and pagination after a revert, clear queued input and obsolete actions, and require a session reload when the revert cannot be confirmed. ## Testing Add regression coverage for reverting earlier and first visible prompts in place, preserving unloaded history and thread state, rejecting steers in clipped history, and clearing streaming output, queued input, and stale approval actions. GitOrigin-RevId: d3f0342539392bdbfec925d0c3d6f67369937f1b
This commit is contained in:
1 parent
8ece31a7bf
commit
ffae979216
16 files changed
+659
-409
No files matched your search
@@ -869,7 +869,6 @@ pub(crate) enum ReplayKind {
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
||||
enum SessionConfiguredDisplay {
|
||||
Normal,
|
||||
PromptEdit,
|
||||
/// Apply session state without emitting the session info cell.
|
||||
Quiet,
|
||||
SideConversation,
|
||||
|
||||
Reference in new issue
Block a user