Commit Graph

6129 Commits

Author SHA1 Message Date
Zanie Blue 876023ac3d Check all files during a dry-run publish instead of stopping at the first failure (#17785)
This may be superseded by #17786 but is also simpler and easier to merge
first.
2026-02-03 20:25:45 +00:00
Zanie Blue 1f1321d842 Bump version to 0.9.29 (#17837) 2026-02-03 13:06:01 -06:00
Mohammad Miadh Angkad 396ff569ca Fix PYTHONHOME inheritance when spawning different Python versions (#17821)
## Summary

Fixes #17814.

When a Python version installed by uv spawns another Python version via
subprocess (e.g., Python 3.12 spawning Python 3.13), the child process
would inherit the parent's `PYTHONHOME` environment variable. This
caused the child Python to load the wrong stdlib, resulting in errors
like `AssertionError: SRE module mismatch`.

The fix removes the check that prevented overwriting an inherited
`PYTHONHOME` value. Now the Windows trampoline always sets `PYTHONHOME`
to the correct directory for non-virtualenv Python installations,
ensuring each Python version uses its own stdlib.

## Test Plan

Tested manually using the reproduction script from the issue:

```
uv python install 3.12
uv python install 3.13

echo "from os import environ;print(environ['PYTHONHOME']);import re" > test.py
python3.12.exe -c "import subprocess; subprocess.run(['python3.13.exe', 'test.py'])"
```

Before: `AssertionError: SRE module mismatch`
After: Runs successfully with correct `PYTHONHOME` pointing to 3.13's
installation.

---------

Co-authored-by: Zanie Blue <contact@zanie.dev>
2026-02-03 17:12:25 +00:00
Zanie Blue 30d1e1e9a1 Improve display of RFC 9457 Problem Detail responses in uv publish server errors (#17787)
We return these from pyx and recently added generic handling (which I
refactor a little here)

I think they could be a bit friendlier in general, but we can futz with
that globally separately.
2026-02-03 14:21:49 +00:00
Zanie Blue 245541e976 Identify the invidividual clients in uv publish trace logs (#17784)
This is a bit of a nit, but we log three request timeouts in a row
without any clarity about what is different about them, e.g.

```
❯ uv publish wheels/* -v
...
DEBUG Using request timeout of 900s
DEBUG Using request timeout of 30s
DEBUG Using request timeout of 900s
```

This adds an identifier to each one
2026-02-02 21:30:38 -06:00
Tim Pickles 50f96967d3 feat: add properties to synthentic & project root (#17820) 2026-02-02 21:46:52 +01:00
konsti f4390158b3 Use long-lived tokens for uv integration tests (#17819)
The previous rotation used limited tokens.
2026-02-02 11:41:27 -06:00
konsti b02dae03ff Set backoff to 10 retries (#17816)
Fix the comment, as 10 total operations means 9 waiting periods in
between.
2026-02-02 18:08:06 +01:00
konsti f5a4fee20b Fix wheel rejections on freethreading+debug builds (#17812)
This is the minimal fix for
https://github.com/astral-sh/uv/issues/17635. We still display the wheel
without debug, but it unbreaks freethreading+debug in general.
2026-02-02 15:13:11 +00:00
Zanie Blue c8eebb59ab Hint on uv version --bump dev similar to pre-release bumps (#17796)
See https://github.com/astral-sh/uv/issues/17792
2026-02-02 08:37:56 -06:00
konsti bd850697cd Rotate CI test tokens (#17810)
It's been 366 days.
2026-02-02 12:06:04 +01:00
Zanie Blue f5fcf93deb Remove special casing for base and default conda environment names (#17758)
Under the `special-conda-env-names` preview feature, instead, just using
our path-based logic.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-01 12:09:48 +00:00
Zanie Blue 6df4b71669 Improve the wording of publish errors during dry-run (#17782) 2026-01-31 14:08:10 -06:00
Zanie Blue 7b5bf635ae Drop bits view from preview flags Debug repr (#17776)
Co-authored-by: Claude <noreply@anthropic.com>
2026-01-30 12:10:58 -06:00
Zanie Blue 9d55baf265 Pad with zeros during comparisons in EqualStar and NotEqualStar operators (#17751)
This is a bug that was found by fuzzing with Claude

> The `==X.Y.*` and `!=X.Y.*` operators use `zip` to compare version
> components, but `zip` stops at the shorter iterator. This caused
> short versions to incorrectly match longer prefix specifiers.
> 
> For example, version "2" (which is semantically "2.0") would
> incorrectly match "==2.1.*" because the `zip` would only compare
> the first component (2 == 2) and never check the second component.
> 
> The fix pads the version with zeros when it's shorter than the
> specifier prefix, matching PEP 440's normalization semantics where
> trailing zeros are implied.

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-30 10:00:33 -06:00
konsti e2ef6216a7 Remove test_generate_json_schema (#17763)
We don't update the schema with every PR anymore.
2026-01-30 13:57:22 +00:00
Zanie Blue 63808421f5 Add wheel-tag-style aliases for manylinux platform names (#17750)
Adds support for wheel-tag-style platform name aliases (with
architecture as a suffix) for all manylinux targets in the
`TargetTriple` enum. For example, `manylinux2014_x86_64` and
`manylinux_2_17_aarch64` are now accepted as aliases alongside the
canonical names like `x86_64-manylinux2014` and
`aarch64-manylinux_2_17`.

I noticed that you can't request these in the format in which they're
displayed as wheel tags which we'll show during a resolution error. I
foolishly just tried to copy and paste from our hint and was surprised
it failed.

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-30 06:36:30 -06:00
github-actions[bot] 71f5849244 Update to Pyodide 0.29.3 (#17730)
Automated update for Python releases.

Co-authored-by: zanieb <2586601+zanieb@users.noreply.github.com>
2026-01-29 21:51:23 -06:00
William Woodruff fc0db7927a Hide a subset of environment variable values in --help (#17745) 2026-01-30 01:58:26 +01:00
Zanie Blue b02ffc5d09 Reject unknown field names in conflict declarations (#17727) 2026-01-29 14:15:51 -06:00
Zanie Blue 0e1351e400 Bump version to 0.9.28 (#17738) 2026-01-29 13:51:05 -06:00
Zanie Blue 1b4407f2e9 Ensure uv.exe exits when uvw.exe or uvx.exe is killed (#17500)
This matches the approach used by the trampoline in `bounce.rs` so we
combine the implementations in a new `uv-windows` crate.

Closes #17492
Closes https://github.com/astral-sh/uv/issues/11817
2026-01-29 11:50:21 -06:00
konsti b273747335 Warn if multiple indexes include default = true (#17713)
Prepare for #17011

Co-authored-by: Charlie Marsh <charlie.r.marsh@gmail.com>
2026-01-29 13:35:06 +01:00
Zanie Blue 583414f2be Add a reflink alias for the "clone" link mode (#17724)
Closes https://github.com/astral-sh/uv/issues/17722
2026-01-28 10:11:27 -06:00
github-actions[bot] c377edcd50 Sync latest Python releases (#17726)
Pick up python-build-standalone 20260127 for OpenSSL 3.5.5.

Co-authored-by: geofft <74644+geofft@users.noreply.github.com>
2026-01-27 21:02:13 -05:00
Charlie Marsh 3a5c343f72 Skip uploads when validation reports 'Already uploaded' (#17412)
## Summary

If the file was already uploaded, `/validate` already tells us that.
2026-01-27 13:45:34 -05:00
Zanie Blue 2183c3fe1b Use Rust 1.91 features Duration::from_mins and Path::with_added_extension (#17710)
Co-authored-by: Claude <noreply@anthropic.com>
2026-01-27 13:16:35 +01:00
Bernát Gábor 5aeaa31a66 Set XDG_CONFIG_HOME in with_real_home() to isolate test config (#17456)
The `with_real_home()` method sets `HOME` to the real home directory,
which is required for tests that use the macOS keychain for
authentication. However, this causes a problem: when `HOME` is set but
`XDG_CONFIG_HOME` is not, uv resolves the config directory to
`$HOME/.config/uv` per the XDG specification. This means tests would
read the user's real configuration files (like `.python-version` or
`uv.toml`), which can override test-specified settings and cause
failures.

This PR sets `XDG_CONFIG_HOME` to the test's isolated config directory
in `with_real_home()`, ensuring that even when the real HOME is needed
for keychain access, configuration files are read from an isolated
location.

## Test plan

- Existing tests pass
- Tests using `with_real_home()` no longer read user config files
2026-01-27 10:46:22 +00:00
Gyeongjae Choi d31d7d7d86 Support Pyodide interpreter in windows (#17658)
## Summary

This adds Pyodide interpreter support in windows environment. In Pyodide
0.29.2, we made some enhancements to run Pyodide CLI in windows. This PR
relaxes a check that was disabling `uv pip` in Windows + Pyodide and
adds integration test.

## Test Plan

Added integration test, also tested locally by running

```
uv python install cpython-3.13.2-emscripten-wasm32-musl
uv venv venv-pyodide -p cpython-3.13.2-emscripten-wasm32-musl
call venv-pyodide\Scripts\activate
uv pip install packaging
python -c "import packaging"
```
2026-01-26 18:39:45 -06:00
Zanie Blue b5797b2ab4 Bump version to 0.9.27 (#17706) 2026-01-26 22:38:10 +00:00
Zanie Blue 4e13f082a8 Upgrade based on outdated build versions in uv python upgrade (#17653) 2026-01-26 15:15:30 -06:00
renovate[bot] ca1ab24477 Update Rust crate http to v1.4.0 (#17518)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [http](https://redirect.github.com/hyperium/http) |
workspace.dependencies | minor | `1.3.1` → `1.4.0` |

---

### Release Notes

<details>
<summary>hyperium/http (http)</summary>

###
[`v1.4.0`](https://redirect.github.com/hyperium/http/blob/HEAD/CHANGELOG.md#140-November-24-2025)

[Compare
Source](https://redirect.github.com/hyperium/http/compare/v1.3.1...v1.4.0)

- Add `StatusCode::EARLY_HINTS` constant for 103 Early Hints.
- Make `StatusCode::from_u16` now a `const fn`.
- Make `Authority::from_static` now a `const fn`.
- Make `PathAndQuery::from_static` now a `const fn`.
- MSRV increased to 1.57 (allows legible const fn panic messages).

</details>

---

### Configuration

📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM, only on
Monday ( * 0-3 * * 1 ) (UTC), Automerge - At any time (no schedule
defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/astral-sh/uv).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi43NC41IiwidXBkYXRlZEluVmVyIjoiNDIuOTIuMSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiYnVpbGQ6c2tpcC1yZWxlYXNlIiwiaW50ZXJuYWwiXX0=-->

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tomasz (Tom) Kramkowski <tom@astral.sh>
2026-01-26 12:45:20 +00:00
renovate[bot] 695a5e18d4 Update Rust crate thiserror to v2.0.18 (#17688)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [thiserror](https://redirect.github.com/dtolnay/thiserror) |
workspace.dependencies | patch | `2.0.17` → `2.0.18` |

---

### Release Notes

<details>
<summary>dtolnay/thiserror (thiserror)</summary>

###
[`v2.0.18`](https://redirect.github.com/dtolnay/thiserror/releases/tag/2.0.18)

[Compare
Source](https://redirect.github.com/dtolnay/thiserror/compare/2.0.17...2.0.18)

- Make compatible with project-level `needless_lifetimes = "forbid"`
([#&#8203;443](https://redirect.github.com/dtolnay/thiserror/issues/443),
thanks
[@&#8203;LucaCappelletti94](https://redirect.github.com/LucaCappelletti94))

</details>

---

### Configuration

📅 **Schedule**: Branch creation - Between 12:00 AM and 03:59 AM, only on
Monday ( * 0-3 * * 1 ) (UTC), Automerge - At any time (no schedule
defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/astral-sh/uv).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi45Mi4xIiwidXBkYXRlZEluVmVyIjoiNDIuOTIuMSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiYnVpbGQ6c2tpcC1yZWxlYXNlIiwiaW50ZXJuYWwiXX0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-01-26 11:06:19 +00:00
Léo Bernard 8ad9cac8fe Fix typo in the documentation of UV_PUBLISH_INDEX (#17672)
## Summary

I added a missing verb to the documentation of `UV_PUBLISH_INDEX`.

## Test Plan

It was not tested.
2026-01-25 21:02:11 -05:00
Charlie Marsh d2b0f1dc23 Add support for ROCm 7.0 and 7.1 (#17681)
## Summary

Closes #17674.
2026-01-24 10:54:03 -05:00
William Woodruff 73410fad33 Fix default handling in PEP 792 status markers (#17671) 2026-01-23 12:48:52 -05:00
Tomasz Kramkowski 6e3ba2f03d Introduce PreviewFeature to clarify intent throughout the codebase (#17670)
## Summary

This PR replaces `bitflags` in favour of `enumflags2` (which we already
transitively depended on) so that `PreviewFeatures` can be replaced with
`PreviewFeature` which is an enum. This clarifies intent in cases where
we only care about one specific `PreviewFeature`.

To avoid a bunch of boilerplate changes, the `Preview` wrapper has been
kept and creation now involves a `&[PreviewFeature]` in all cases. The
alternative was to have everything which initialises a `Preview` use
`BitFlags` directly and possibly to remove `Preview` entirely but this
keeps things simpler and limits the changes throughout the rest of the
codebase solely to changes which deal with the name changes (ALL_CAPS to
PascalCase) and the impact on `--show-settings` which I don't believe we
care about stability of output for?

The changes to `--show-settings` could be avoided with some custom
`Debug` implementation but that seems excessive.

This PR will impact #16452. But the changes were inspired by trying to
remove the need for that particular PR to add more runtime type
checking.

## Test Plan

Existing tests were adjusted (I also fixed some missing cases). The test
for panicking in cases which are now prevented through the use of type
changes has been dropped. All the rest of the tests were ran, snapshot
changes reviewed and applied.
2026-01-23 17:19:23 +00:00
William Woodruff ffb45112ab PEP 792: plumb statuses into internal representation (#17631) 2026-01-23 10:29:39 -05:00
William Woodruff 7728392641 Fix schema for PackageExcludeNewer (#17665) 2026-01-22 17:45:50 -05:00
konsti c72a5a2ee5 Fix test isolation for uv publish (#17659)
For https://github.com/astral-sh/uv/issues/17509#issuecomment-3761569350
2026-01-22 15:26:59 +01:00
konsti 2458d4835d Remove unused error enum variants (#17657) 2026-01-22 12:31:55 +01:00
github-actions[bot] 0b59a9ef3f Upgrade Pyodide to 0.29.2 (#17652)
Automated update for Python releases.

Co-authored-by: zanieb <2586601+zanieb@users.noreply.github.com>
2026-01-22 00:47:11 +00:00
Zanie Blue e0b4369ee4 Improve warnings for --system and --no-system in uv venv (#17647)
See #17641

Co-authored-by: Claude <noreply@anthropic.com>
2026-01-21 18:11:02 -06:00
konsti 7516b79b7b Better detection for conflicting packages (#17623)
In the previous iteration, conflict detection was based on top level
modules. This would work if all namespace packages correctly omitted the
`__init__.py`, but e.g. the nvidia packages include an empty
`nvida/__init__.py`.

Instead, we track overlapping top level modules during installation and
perform conflict analysis after installation, recursing only as far as
necessary.

See https://github.com/astral-sh/uv/pull/13437 for a list of reported
conflicts.

Before:
```
$ uv venv -c -q && uv pip install --preview nvidia-nvjitlink-cu12==12.8.93 nvidia-nvtx-cu12==12.8.90
  Resolved 2 packages in 0.99ms
  ░░░░░░░░░░░░░░░░░░░░ [0/2] Installing wheels...                                                    warning: The module `nvidia` is provided by more than one package, which causes an install race condition and can result in a broken module. Consider removing your dependency on either `nvidia-nvtx-cu12` (v12.8.90) or `nvidia-nvjitlink-cu12` (v12.8.93).
  Installed 2 packages in 3ms
   + nvidia-nvjitlink-cu12==12.8.93
   + nvidia-nvtx-cu12==12.8.90
```

After:
```
$ uv venv -c -q && cargo run -q pip install --preview nvidia-nvjitlink-cu12==12.8.93 nvidia-nvtx-cu12==12.8.90
  Resolved 2 packages in 3ms
  Installed 2 packages in 4ms
   + nvidia-nvjitlink-cu12==12.8.93
   + nvidia-nvtx-cu12==12.8.90
```

Still detected true positive:
```
$ uv venv -c -q && cargo run -q pip install --no-progress opencv-python opencv-contrib-python --no-build --no-deps --preview
  Resolved 2 packages in 5ms
warning: The file `cv2/__init__.pyi` is provided by more than one package, which causes an install race condition and can result in a broken module. Packages containing the file:
* opencv-contrib-python (opencv_contrib_python-4.13.0.90-cp37-abi3-manylinux_2_28_x86_64.whl)
* opencv-python (opencv_python-4.13.0.90-cp37-abi3-manylinux_2_28_x86_64.whl)
Installed 2 packages in 6ms
 + opencv-contrib-python==4.13.0.90
 + opencv-python==4.13.0.90
```
2026-01-21 17:34:56 +01:00
github-actions[bot] ed32e78e21 Upgrade to GraalPy 25.0.2 (#17634)
Automated update for Python releases.

Co-authored-by: zanieb <2586601+zanieb@users.noreply.github.com>
2026-01-21 09:21:46 -06:00
konsti 7c9c75d267 Fix torch ecosystem check (#17637)
Jaxlib removed old releases we had locked, see
https://github.com/jax-ml/jax/issues/34532. I hacked out the version
bound :/
2026-01-21 12:01:02 +00:00
William Woodruff ba1306430e Support Trusted Publishing with pyx (#17438) 2026-01-20 22:18:26 +00:00
Zanie Blue 3e22637c93 Use #[expect(clippy::...)] throughout and drop unused supressions (#17537)
Co-authored-by: Claude <noreply@anthropic.com>
2026-01-20 21:52:06 +00:00
konsti ba534b1038 Less manual Command::new in integration tests (#17625)
Improve test consistency a bit, with an eye towards environment variable
usage.

Notably, use `TestContext::pip_uninstall` and `TestContext::pip_tree`
over `Command::new`.
2026-01-20 15:54:20 +00:00
konsti 231fda3f3f Remove some more text env special casing (#17531)
Part of https://github.com/astral-sh/uv/pull/14080
2026-01-20 10:31:10 +00:00