Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Retain cancel callback until ForEachAsync completes #1981

Merged
merged 1 commit into from
Jul 27, 2023

Conversation

idg10
Copy link
Collaborator

@idg10 idg10 commented Jul 27, 2023

Resolves #1940

The code that waits for processing to complete was after the closing brace of the using that unregisters the cancellation callback. This meant that it almost immediately unregistered for cancellation notifications. Simply moving that await inside the relevant block addresses this.

@idg10 idg10 self-assigned this Jul 27, 2023
@idg10 idg10 merged commit 5903ac6 into main Jul 27, 2023
@idg10 idg10 deleted the feature/1940-asyncrx-foreachasync-ignores-cancel branch July 27, 2023 21:24
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.

ForEachAsync continues after cancellation token is cancelled
2 participants