Skip to content

fix: add missing ConfigureAwait(false) in PageIterator to prevent deadlocks - #1122

Open
Hardik K (hardikkaurani) wants to merge 1 commit into
microsoftgraph:mainfrom
hardikkaurani:fix/page-iterator-configure-await
Open

Hardik K (hardikkaurani) wants to merge 1 commit into
microsoftgraph:mainfrom
hardikkaurani:fix/page-iterator-configure-await

Conversation

@hardikkaurani

@hardikkaurani Hardik K (hardikkaurani) commented Oct 22, 2026 •

Copy link
Copy Markdown

Fixes #1059

Changes proposed in this pull request

  • Add .ConfigureAwait(false) to async callback invocations and page dispatch awaits in PageIterator (IntrapageIterateAsync, InterpageIterateAsync, and IterateAsync).
  • Aligns with existing ConfigureAwait(false) usage across PageIterator (e.g. lines 295, 315, 327, 345, 361) to prevent synchronization context deadlocks when consuming pagination in mixed sync/async contexts.
Microsoft Reviewers: Open in CodeFlow

@hardikkaurani
Hardik K (hardikkaurani) requested a review from a team as a code owner October 22, 2026 08:00
Copilot AI balanced review requested due to automatic review settings October 22, 2026 08:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@hardikkaurani

Copy link
Copy Markdown
Author

Hi Gavin Barron (@gavinbarron), opened this PR to resolve #1059 by adding the missing ConfigureAwait(false) calls in PageIterator to prevent deadlocks when consumed in mixed sync/async contexts. Whenever you have time, please take a look. Thank you!

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Missing ConfigureAwait in PageIterator.IntrapageIterateAsync

2 participants