Skip to content

Resume conversation from an earlier point in history - #2588

Closed
aibrahim-oai wants to merge 11 commits into
mainfrom
new_conv_tui
Closed

aibrahim-oai wants to merge 11 commits into
mainfrom
new_conv_tui

Conversation

@aibrahim-oai

@aibrahim-oai aibrahim-oai commented Aug 22, 2025 •

Copy link
Copy Markdown
Contributor

based on #2575

Screen.Recording.2025-08-22.at.10.34.59.AM.mov

@aibrahim-oai
aibrahim-oai changed the base branch from main to new_conversation August 22, 2025 17:40

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Codex Review: Here are some suggestions.

[P1] Reset backtrack state when transcript overlay closes

[app.rs:170-175] Closing the transcript overlay with “q”, Ctrl‑T or Ctrl‑C leaves esc_backtrack_primed, esc_backtrack_base and esc_backtrack_count unchanged. close_transcript_overlay sets transcript_overlay_is_backtrack to false (lines 444‑455), but handle_tui_event tries to clear the state after calling this function only if transcript_overlay_is_backtrack is still true (lines 170‑176). The check therefore never executes, leaving the application in a primed state. Subsequent presses of Enter (with an empty composer) or Esc will unexpectedly fork the earlier conversation using stale counts and IDs.

[P1] NewSession does not clear Esc‑backtrack state

[app.rs:222-375] AppEvent::NewSession replaces the ChatWidget but does not reset the backtracking fields esc_backtrack_primed, esc_backtrack_base, or esc_backtrack_count (lines 222‑233). The Esc‑handling logic (lines 360‑376) assumes these fields start fresh for each session. If the user had primed backtracking in a previous session, the first Esc in the new session immediately opens the overlay using the previous conversation id, and confirming will fork that old conversation. The user cannot backtrack the current session until the stale state is manually cleared, and accidental confirmation forks the wrong conversation.

Reply with @codex fix comments to fix any unresolved comments.

About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you open a pull request for review, mark a draft as ready, or comment "@codex review". If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex fix this CI failure" or "@codex address that feedback".

aibrahim-oai added a commit that referenced this pull request Aug 23, 2025
This can be the underlying logic in order to start a conversation from a
previous message. will need some love in the UI.

Base for building this: #2588
Base automatically changed from new_conversation to main August 23, 2025 00:06
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 23, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant