Skip to content

Conversation

@nathansobo
Copy link
Contributor

@nathansobo nathansobo commented Dec 14, 2025

Release Notes:

  • Fixed spurious "no checkpoint" error in agent panel

Summary

update_last_checkpoint would call last_user_message() twice - once at the start to capture the checkpoint, and again in an async closure after the checkpoint comparison completed. If a new user message without a checkpoint was added between these two calls, the second call would find the new message and fail with "no checkpoint".

Fix

Capture the user message ID at the start and use user_message_mut(&id) in the async closure to find the specific message.

cc @mikayla-maki

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Dec 14, 2025
update_last_checkpoint would call last_user_message() twice - once at the
start to capture the checkpoint, and again in an async closure after the
checkpoint comparison completed. If a new user message without a checkpoint
was added between these two calls, the second call would find the new message
and fail with 'no checkpoint'.

Fix by capturing the user message's ID at the start and using
user_message_mut(&id) in the async closure to find the specific message.
@nathansobo nathansobo force-pushed the fix-update-last-checkpoint-race branch from f146f02 to a98f402 Compare December 14, 2025 08:40
@MrSubidubi MrSubidubi changed the title Fix race condition in update_last_checkpoint Fix race condition in update_last_checkpoint Dec 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants