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

check data stream closed #369

Merged
merged 2 commits into from
Feb 25, 2025
Merged

check data stream closed #369

merged 2 commits into from
Feb 25, 2025

Conversation

longcw
Copy link
Contributor

@longcw longcw commented Feb 25, 2025

No description provided.

@longcw longcw requested a review from lukasIO February 25, 2025 08:08
@@ -235,6 +240,8 @@ async def _send_trailer(self, trailer: proto_DataStream.Trailer):
if cb.send_stream_chunk.error:
raise ConnectionError(cb.send_stream_trailer.error)

self._closed = True
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we should set self._closed = True already in the aclose method before awaiting sending of the trailer

Copy link
Contributor

Choose a reason for hiding this comment

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

and therefore also move the self._closed check into the aclose method

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah, makes sense

@longcw longcw requested a review from lukasIO February 25, 2025 11:05
@longcw longcw merged commit 361f1ea into main Feb 25, 2025
12 checks passed
@longcw longcw deleted the longc/check-stream-closed branch February 25, 2025 13:10
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