mirror of
https://github.com/astral-sh/uv.git
synced 2025-07-07 21:35:00 +00:00
Add Accept-Encoding: identity
to remaining stream paths (#2321)
## Summary Like #2319, there are a few other places where we attempt to stream a file.
This commit is contained in:
parent
a9c00024a7
commit
6866a55f20
3 changed files with 28 additions and 0 deletions
|
@ -259,6 +259,13 @@ impl<'a, Context: BuildContext + Send + Sync> DistributionDatabase<'a, Context>
|
|||
.cached_client()
|
||||
.uncached()
|
||||
.get(wheel.url.raw().clone())
|
||||
.header(
|
||||
// `reqwest` defaults to accepting compressed responses.
|
||||
// Specify identity encoding to get consistent .whl downloading
|
||||
// behavior from servers. ref: https://github.com/pypa/pip/pull/1688
|
||||
"accept-encoding",
|
||||
reqwest::header::HeaderValue::from_static("identity"),
|
||||
)
|
||||
.build()?;
|
||||
let cache_control = match self.client.connectivity() {
|
||||
Connectivity::Online => CacheControl::from(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue