ort icon indicating copy to clipboard operation
ort copied to clipboard

feat: Add Uv Python package manager

Open heliocastro opened this issue 8 months ago • 4 comments

Uv is Astral.sh Python package/project manager solution. The backend is based on Rust and is a merge result of two projects, the original package manager uv and the Python project manager rye,

Reference:

heliocastro avatar Mar 11 '25 08:03 heliocastro

Codecov Report

:x: Patch coverage is 48.00000% with 13 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 56.46%. Comparing base (88015b4) to head (d97afdf). :warning: Report is 878 commits behind head on main.

Files with missing lines Patch % Lines
...nagers/python/src/main/kotlin/utils/PythonUtils.kt 57.89% 1 Missing and 7 partials :warning:
...ommands/repoconfig/GenerateScopeExcludesCommand.kt 0.00% 5 Missing :warning:
Additional details and impacted files
@@             Coverage Diff              @@
##               main   #10020      +/-   ##
============================================
- Coverage     56.48%   56.46%   -0.02%     
+ Complexity     1611     1609       -2     
============================================
  Files           331      331              
  Lines         12268    12293      +25     
  Branches       1138     1147       +9     
============================================
+ Hits           6929     6941      +12     
- Misses         4896     4902       +6     
- Partials        443      450       +7     
Flag Coverage Δ
funTest-non-docker 33.40% <0.00%> (-0.21%) :arrow_down:
test-ubuntu-24.04 40.39% <48.00%> (+0.03%) :arrow_up:
test-windows-2022 40.37% <48.00%> (+0.03%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

codecov[bot] avatar Mar 11 '25 17:03 codecov[bot]

Just as a somewhat related remark, Dependabot now can also handle uv.

sschuberth avatar Mar 14 '25 08:03 sschuberth

Just as a somewhat related remark, Dependabot now can also handle uv.

Right on time, i say

heliocastro avatar Mar 14 '25 14:03 heliocastro

I believe this needs major rework for work without python-inspector, which is know to have several problems.

So I guess we'd want https://github.com/astral-sh/uv/issues/4711 to be implemented.

sschuberth avatar Mar 17 '25 17:03 sschuberth

I'm closing this one as idea sounds correct in at that moment, but not anymore. Rely only on python inspector with corner cases bugs added the tricky Uv export process, i.e. some python inspector code need to be changed to properly manage some requirements exports, makes the entire thing more problematic than the expected solve the the problem.

The correct approach will be rely on the https://peps.python.org/pep-0751/ as package managers move to that logic, and fallback first level for native lock files for pre-PEP times and as last resort on older but setuputils based code, python-inspector for requirements.txt

heliocastro avatar Oct 30 '25 09:10 heliocastro