uv/crates/uv-client
Charlie Marsh e9c16e9aa2
Enable TLS native root toggling at runtime (#2362)
## Summary

It turns out that on macOS, reading the native certificates can add
hundreds of milliseconds to client initialization. This PR makes
`--native-tls` a command-line flag, to toggle (at runtime) the choice of
the `webpki` roots or the native system roots.

You can't accomplish this kind of configuration with the `reqwest`
builder API, so instead, I pulled out the heart of that logic from the
crate
(e319263851/src/async_impl/client.rs (L498)),
and modified it to allow toggling a choice of root.

Note that there's an open PR for this in reqwest
(https://github.com/seanmonstar/reqwest/pull/1848), along with an issue
(https://github.com/seanmonstar/reqwest/issues/1843), which I may ping,
but it's been around for a while and I believe reqwest is focused on its
next major release.

Closes https://github.com/astral-sh/uv/issues/2346.
2024-03-12 04:05:49 +00:00
..
src Enable TLS native root toggling at runtime (#2362) 2024-03-12 04:05:49 +00:00
tests feat: Add netrc authentication to uv-client (#2241) 2024-03-06 20:48:30 +00:00
Cargo.toml Enable TLS native root toggling at runtime (#2362) 2024-03-12 04:05:49 +00:00
README.md Rename to `uv` (#1302) 2024-02-15 11:19:46 -06:00

README.md

pypi-client

A general-use client for interacting with PyPI.

Loosely modeled after Orogene's oro-client.