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

fix(client): properly cancel contexts in proposal pagination #20

Merged
merged 1 commit into from
Nov 17, 2024

Conversation

d0tsh
Copy link
Contributor

@d0tsh d0tsh commented Nov 15, 2024

Previously, context cancellation was deferred until function return potentially leading to resource leakage during pagination. Now each context is cancelled immediately after its request completes.

Changed in both v1 and v1beta1 proposal clients:

  • Move context cancellation after each request
  • Remove deferred cancellation
  • Maintain same pagination and error handling logic

Copy link
Contributor

@mkaczanowski mkaczanowski left a comment

Choose a reason for hiding this comment

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

lgtm, thanks!

@mkaczanowski mkaczanowski merged commit 50c99b9 into ChorusOne:main Nov 17, 2024
2 checks passed
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.

2 participants