PIP vs UV: The Future of Python Package Management?

Поділитися
Вставка
  • Опубліковано 20 сер 2024

КОМЕНТАРІ • 16

  • @JakeCallahan
    @JakeCallahan  5 місяців тому +5

    I have switched to using uv for virtual environment creation and installation of IPython. With the user-level caching, setup/install went from 5.674s down to 0.451s, and with a complete cache just 0.078s!

    • @rafiqrushdan
      @rafiqrushdan 5 місяців тому

      impressive

    • @0xZarathustra
      @0xZarathustra 5 місяців тому

      issue is tho that it's dependency resolver is not as good as poetry. I don't have a overly complicated setup, but need to downgrade pyyaml during the setup. Poetry does this without issue, `uv pip install pyyaml==5.4.1` just crashes.
      Well, not only that, the fact that the lock files are not system and platform independent... pretty terrible
      you gain seconds during the setup of the environment - if it can find the packages that is ... - only to lose all of those seconds and many more hours when you need to ensure compatibility with other systems and platforms 💀

    • @JakeCallahan
      @JakeCallahan  5 місяців тому

      The team certainly has areas to improve, and it will be interesting to see how they handle things like resolver optimization. As you saw in the video, it had trouble with one of my team's projects.
      Thanks for weighing in!

  • @vortex2210
    @vortex2210 5 місяців тому +2

    Would definitely love to see a comparison between Poetry and uv since all of our projects have been moved to poetry some time back. But this is quite interesting!!

    • @JakeCallahan
      @JakeCallahan  5 місяців тому

      That would be a great follow-up once the project is more mature.

    • @vortex2210
      @vortex2210 5 місяців тому

      @@JakeCallahan yaa, currently I feel the lockfile system works quite well and the envs are easy to manage. I hope uv too gets there soon!

  • @dragonkat13
    @dragonkat13 5 місяців тому

    interesting! look forward to seeing how it unfolds! thank you for covering it! what is your favorite thing about PIP, favorite about UV?

    • @JakeCallahan
      @JakeCallahan  5 місяців тому

      pip's compatibility is hard to beat, so it's still the king of production environments. However, I think UV is well positioned to win out in the long term, if Astral can fulfill their vision.

  • @mews75
    @mews75 5 місяців тому +2

    I mean the speed is cool but not being able to install all pypi packages is enough for me to not use it

    • @JakeCallahan
      @JakeCallahan  5 місяців тому +2

      It's definitely not mature enough yet, but the team moves pretty fast and has an active community, so hopefully they can get most of the big issues I ran into fixed soon.

  • @B3L13V3R
    @B3L13V3R 27 днів тому

    I didn't have any of these issues testing the same on an M1 Max in late July 2024. Hope it helps.

    • @JakeCallahan
      @JakeCallahan  27 днів тому +1

      The team and community has done a great job with uv since then. It is now my daily driver for package management. I'll need to do an update video sometime soon.

    • @B3L13V3R
      @B3L13V3R 27 днів тому

      @@JakeCallahan Awesome! The video is a go-to for the potential for uv.

  • @ash1kh
    @ash1kh 2 місяці тому

    Thats why i use poetry if i do any python related stuff.