uv/scripts
Zanie Blue 6856a27711
Add `extra-build-dependencies` (#14735)
Replaces https://github.com/astral-sh/uv/pull/14092

Adds `tool.uv.extra-build-dependencies = {package = [dependency, ...]}`
which extends `build-system.requires` during package builds.

These are lowered via workspace sources, are applied to transitive
dependencies, and are included in the wheel cache shard hash.

There are some features we need to follow-up on, but are out of scope
here:

- Preferring locked versions for build dependencies
- Settings for requiring locked versions for build depencies

There are some quality of life follow-ups we should also do:

- Warn on `extra-build-dependencies` that do not apply to any packages
- Add test cases and improve error messaging when the
`extra-build-dependencies` resolve fails


-------

There ~are~ were a few open decisions to be made here

1. Should we resolve these dependencies alongside the
`build-system.requires` dependencies? Or should we resolve separately?
(I think the latter is more powerful? because you can override things?
but it opens the door to breaking your build)
2. Should we install these dependencies into the same environment? Or
should we layer it on top as we do elsewhere? (I think it's fine to
install into the same environment)
3. Should we respect sources defined in the parent project? (I think
yes, but then we need to lower the dependencies earlier — I don't think
that's a big deal, but it's not implemented)
4. Should we respect sources defined in the child project? (I think no,
this gets really complicated and seems weird to allow)
5. Should we apply this to transitive dependencies? (I think so)

---------

Co-authored-by: Aria Desires <aria.desires@gmail.com>
Co-authored-by: konstin <konstin@mailbox.org>
2025-07-30 09:53:07 -05:00
..
benchmark Upgrade to the latest Ruff version (#10433) 2025-01-09 10:47:25 -05:00
links Hint at `tool.uv.required-environments` (#13575) 2025-06-06 19:15:52 +00:00
packages Add `extra-build-dependencies` (#14735) 2025-07-30 09:53:07 -05:00
popular_packages Update top-pypi-packages filename (#11959) 2025-03-04 18:23:02 -05:00
publish Fix PyPI publish test script (#14116) 2025-06-18 09:51:53 +02:00
requirements Add second apache airflow test case (#10463) 2025-01-10 15:42:03 +01:00
scenarios Unify test venv `python` command creation (#14117) 2025-06-18 15:06:09 +02:00
smoke-test Add `--version` to smoke tests (#12516) 2025-03-27 20:45:25 +00:00
workspaces Fix Ruff linting (#14111) 2025-06-17 17:28:23 +00:00
check_cache_compat.py Set absolute URLs prior to uploading to PyPI (#5038) 2024-07-13 17:29:21 +00:00
check_embedded_python.py Set absolute URLs prior to uploading to PyPI (#5038) 2024-07-13 17:29:21 +00:00
check_registry.py Install and remove managed Python to and from the Windows Registry (PEP 514) (#10634) 2025-01-23 14:13:41 +00:00
check_system_python.py Display `sys.executable` names in check system jobs (#14656) 2025-07-16 09:17:01 -05:00
create-python-mirror.py Add additional version filter to mirror script. (#10055) 2024-12-20 12:50:59 -06:00
registries-test.py Re-enable Artifactory in the registries integration test (#14408) 2025-07-02 13:50:35 +02:00
release.sh Remove the preview changelog (#6259) 2024-08-20 16:47:46 +00:00
reverse-changelog.py Reverse and format the archived changelogs (#12099) 2025-03-12 11:58:51 -05:00
sync_scenarios.sh Update packse scenarios (#13688) 2025-05-28 08:58:38 -05:00
transform_readme.py Fix Ruff linting (#14111) 2025-06-17 17:28:23 +00:00
update_schemastore.py Update SchemaStore script (#5024) 2024-07-12 17:49:38 -04:00
uv-run-remote-script-test.py Pin rich==13.7.1 for --exclude-newer in tests (#7713) 2024-09-26 11:54:50 -04:00