[Python] Showing package specifiers

Discussão em 'Python' iniciado por Stack, Dezembro 9, 2024.

  1. Stack

    Stack Membro Participativo

    In my project, which I manage with uv, some transitive dependency is restricting numpy to numpy==2.0; even though the newest version is numpy=2.2.

    Is there any convenient way to make uv tell me what the cause of this restriction in my dependency tree is?

    I can get halfway there by uv tree --invert --package numpy, resulting in (redacted):

    numpy v2.0.2
    ├── numba v0.60.0
    | └── my_main_project v0.1.0
    ├── matplotlib v3.9.3
    └── scipy v1.14.1


    However, this is forcing me to walk the respective packages by hand to find the restriction.

    Much more convenient here (pip install pipdeptree):

    $ pipdeptree -r -p numpy
    numpy==2.0.2
    ├── numba==0.60.0 [requires: numpy>=1.22,<2.1]
    │ └── my_main_project v0.1.0 [requires: numba>=0.60]
    ├── matplotlib==3.9.3 [requires: numpy>=1.23]
    ...
    └── scipy==1.14.1 [requires: numpy>=1.23.5,<2.3]


    Is there any way to produce this with native uv?

    Continue reading...

Compartilhe esta Página