Fix restoring cloud conversation transcripts#10385
Conversation
|
I'm starting a first review of this pull request. You can view the conversation on Warp. I completed the review and no human review was requested for this pull request. Comment Powered by Oz |
harryalbert
left a comment
There was a problem hiding this comment.
nice, thanks for fixing
There was a problem hiding this comment.
Overview
This PR updates restored ambient-agent transcript panes to load by server conversation token, allowing the history model to fall back to a direct server fetch when local metadata does not contain the token.
Concerns
- No blocking correctness, error handling, or security concerns found in the reviewed diff.
Verdict
Found: 0 critical, 0 important, 0 suggestions
Approve
Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).
Powered by Oz
Description
Fix cloud conversation transcript viewer pane getting permanently stuck in the loading state after quit and restart.
When a pane was viewing a cloud conversation transcript (from an ambient agent run), the pane is saved as an
AmbientAgentsnapshot. On restore, it creates a loading pane and defers restoration until task data arrives from the server. The deferred handler callsfetch_and_load_transcript, which used a two-step lookup: firstfind_conversation_id_by_server_tokento map the server token to a localAIConversationId, thenload_conversation_data. If the conversation's metadata wasn't included in the initial cloud metadata fetch (e.g., 3 requested but only 2 returned), the token was never found locally. The task was re-inserted into the pending restorations map, but no further events fired to retry — leaving the pane stuck inLoadingforever.The fix switches
fetch_and_load_transcriptto useload_conversation_by_server_token, which already has a built-in server fallback when the token isn't in the local cache.Testing
Quit Warp while a pane is viewing a cloud conversation transcript
Restart Warp
Verify the pane loads the conversation transcript instead of staying in the loading spinner
I have manually tested my changes locally with
./script/runhttps://www.loom.com/share/58201254f6014ef496b25fbe78472eb6
Agent Mode
Changelog Entries for Stable
CHANGELOG-BUG-FIX: Fixed cloud conversation transcript pane getting stuck in loading state after restarting Warp