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

Add content length to async_impl::multipart file streams #2459

Merged
merged 1 commit into from
Oct 27, 2024

Conversation

Mr-Pine
Copy link
Contributor

@Mr-Pine Mr-Pine commented Oct 27, 2024

In contrast to the blocking version, the async version of Part::file does not set the content length.
The blocking version does this via Body::from(file: File) while the async version calls Part::stream. This PR changes this to the async version to Part::stream_with_length if a file length is available.

@seanmonstar seanmonstar enabled auto-merge (squash) October 27, 2024 20:38
@seanmonstar seanmonstar merged commit 598f857 into seanmonstar:master Oct 27, 2024
8 of 9 checks passed
kodiakhq bot pushed a commit to pdylanross/fatigue that referenced this pull request Oct 29, 2024
⚠️  Dependabot is rebasing this PR ⚠️
Rebasing might not happen immediately, so don't worry if this takes some time.
Note: if you make any changes to this PR yourself, they will take precedence over the rebase.

Bumps reqwest from 0.12.8 to 0.12.9.

Release notes
Sourced from reqwest's releases.

v0.12.9
What's Changed

Add tls::CertificateRevocationLists support (by @​ksenia-vazhdaeva in seanmonstar/reqwest#2433)
Add crate features to enable webpki roots without selecting a rustls provider (by @​stevefan1999-personal in seanmonstar/reqwest#2447)
Fix multipart::Part::file() to automatically include content-length (by @​Mr-Pine in seanmonstar/reqwest#2459)
Fix proxy to internally no longer cache system proxy settings (by @​lanyeeee in seanmonstar/reqwest#2442)
Fix connection_verbose() to output read logs (by @​seanmonstar in seanmonstar/reqwest#2454)

New Contributors

@​lanyeeee made their first contribution in seanmonstar/reqwest#2442
@​ksenia-vazhdaeva made their first contribution in seanmonstar/reqwest#2433
@​Mr-Pine made their first contribution in seanmonstar/reqwest#2459
@​stevefan1999-personal made their first contribution in seanmonstar/reqwest#2447

Full Changelog: seanmonstar/[email protected]



Changelog
Sourced from reqwest's changelog.

v0.12.9

Add tls::CertificateRevocationLists support.
Add crate features to enable webpki roots without selecting a rustls provider.
Fix connection_verbose() to output read logs.
Fix multipart::Part::file() to automatically include content-length.
Fix proxy to internally no longer cache system proxy settings.




Commits

797df2b v0.12.9
64aa7d1 add webpki roots option for rustls no provider setup (#2447)
598f857 Add content length to async_impl::multipart file streams (#2459)
d99e90d fix: re-enable verbose connection read logs (#2454)
aba01ff feat: Add support for Certificate Revocation Lists (#2433)
3ad6e02 refactor: remove internal proxy sys cache (#2442)
See full diff in compare view




Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

@dependabot rebase will rebase this PR
@dependabot recreate will recreate this PR, overwriting any edits that have been made to it
@dependabot merge will merge this PR after your CI passes on it
@dependabot squash and merge will squash and merge this PR after your CI passes on it
@dependabot cancel merge will cancel a previously requested merge and block automerging
@dependabot reopen will reopen this PR if it is closed
@dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
@dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
@dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
@dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
@dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Nutomic pushed a commit to Nutomic/reqwest that referenced this pull request Nov 7, 2024
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