[ENG-11736] pass downloaded bytes, IP and completed flag to callback#494
Open
ihorsokhanexoft wants to merge 2 commits into
Open
[ENG-11736] pass downloaded bytes, IP and completed flag to callback#494ihorsokhanexoft wants to merge 2 commits into
ihorsokhanexoft wants to merge 2 commits into
Conversation
sh-andriy
requested changes
Jul 17, 2026
sh-andriy
left a comment
Collaborator
There was a problem hiding this comment.
Looks good overall thanks.
Just one thing that i noticed:
Saw your note - completed on 200/302 from the provider catches provider-side failures, but not the client cancelling mid-download. WB's already sent 200 once it starts streaming, and write_stream swallows the disconnect, so a user who aborts a big zip still lands as completed=True with only partial bytes. The client specifically wants to tell finished vs aborted apart, so we'd need the StreamClosedError signal out of write_stream, not just the response status.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://openscience.atlassian.net/browse/ENG-11736
In the payload the following properties appear now:

download_file,download_zipactions are marked as completed only if we get 200 or 302 from a provider