Skip to content

Conversation

@lokitoth
Copy link
Member

Description

Flushes the index file on checkpoint creation to ensure we get disk status current when control returns to user code after the checkpoint.

Fixes #3169

Contribution Checklist

  • The code builds clean without any errors or warnings
  • The PR follows the Contribution Guidelines
  • All unit tests pass, and I have added new tests where possible
  • Is this a breaking change? If yes, add "[BREAKING]" prefix to the title of the PR.

@lokitoth lokitoth added the .NET label Jan 26, 2026
Copilot AI review requested due to automatic review settings January 26, 2026 14:37
@lokitoth lokitoth added the workflows Related to Workflows in agent-framework label Jan 26, 2026
@lokitoth lokitoth force-pushed the dev/dotnet_workflow/fix_filesystemcheckpointstore_does_not_flush branch from de443d8 to 4bd50f3 Compare January 26, 2026 14:39
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes FileSystemJsonCheckpointStore so the index (index.jsonl) is flushed during checkpoint creation, ensuring the on-disk index is up to date when CreateCheckpointAsync returns (addresses #3169).

Changes:

  • Flush index.jsonl after appending a checkpoint entry in CreateCheckpointAsync.
  • Add a unit test verifying the index file has non-zero length before the store is disposed.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
dotnet/src/Microsoft.Agents.AI.Workflows/Checkpointing/FileSystemJsonCheckpointStore.cs Flushes the index stream after writing a new checkpoint entry.
dotnet/tests/Microsoft.Agents.AI.Workflows.UnitTests/FileSystemJsonCheckpointStoreTests.cs Adds coverage to ensure index data is persisted prior to store disposal.

@lokitoth lokitoth force-pushed the dev/dotnet_workflow/fix_filesystemcheckpointstore_does_not_flush branch from 4bd50f3 to 86e7226 Compare January 26, 2026 14:59
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

@lokitoth lokitoth enabled auto-merge January 26, 2026 15:58
@lokitoth lokitoth force-pushed the dev/dotnet_workflow/fix_filesystemcheckpointstore_does_not_flush branch from 86e7226 to 95cb660 Compare January 26, 2026 17:17
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 26, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 26, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 26, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 27, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 27, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 27, 2026
@lokitoth lokitoth removed this pull request from the merge queue due to a manual request Jan 27, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 27, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 27, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 27, 2026
@lokitoth lokitoth added this pull request to the merge queue Jan 27, 2026
Merged via the queue into main with commit 5ef12a2 Jan 27, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

.NET workflows Related to Workflows in agent-framework

Projects

None yet

Development

Successfully merging this pull request may close these issues.

.NET: [Bug]: The FileSystemJsonCheckpointStore did not save the "index.jsonl" file.

4 participants