PrefectHQ
prefect
BlogDocsChangelog

make uv an optional dependency

#19668
Comparing
nate/make-uv-optional
(
3faee93
) with
main
(
c5d255d
)
CodSpeed Performance Gauge
0%
Untouched
2
Ignored
6

Benchmarks

Passed

bench_import_prefect_flow
benches/bench_import.py
CodSpeed Performance Gauge
0%
1.4 s1.4 s
bench_task_decorator
benches/bench_tasks.py
CodSpeed Performance Gauge
0%
461.6 µs463 µs

Ignored

bench_flow_call[options0]
benches/bench_flows.py
Ignored
CodSpeed Performance Gauge
-1%
165.6 ms168 ms
bench_flow_call[options1]
benches/bench_flows.py
Ignored
CodSpeed Performance Gauge
-1%
106.3 ms107.6 ms
bench_import_prefect
benches/bench_import.py
Ignored
CodSpeed Performance Gauge
0%
1.1 s1.1 s
bench_task_submit
benches/bench_tasks.py
Ignored
CodSpeed Performance Gauge
-54%
7.3 ms15.7 ms
bench_flow_decorator
benches/bench_flows.py
Ignored
CodSpeed Performance Gauge
-9%
5.2 ms5.8 ms
bench_task_call
benches/bench_tasks.py
Ignored
CodSpeed Performance Gauge
-7%
31.8 ms34.1 ms

Commits

Click on a commit to change the comparison range
Base
main
c5d255d
-0.16%
make uv an optional dependency Move `uv` from required dependencies to an optional `[uv]` extra. When uv package is not available, behavior depends on the feature: 1. `install_packages()` / `ainstall_packages()` in `_internal/installation.py`: - Falls back to pip with a deprecation warning - This maintains existing behavior (pip fallback was always there) 2. Bundle features in `_experimental/bundles/__init__.py`: - Falls back to system `uv` binary (assumes uv is in PATH) with deprecation warning - NO pip fallback here because `uv pip freeze --exclude-editable` has no pip equivalent - Docker base image includes `/bin/uv` so this works for containerized deployments This addresses #17850 where users on platforms without pre-built uv wheels (requiring Rust toolchain) or wanting smaller container images can now use Prefect without the uv Python package dependency. Closes #17850 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
3faee93
9 hours ago
by zzstoatzz
© 2025 CodSpeed Technology
Home Terms Privacy Docs