pypa / installer

A low-level library for installing from a Python wheel distribution.
https://installer.readthedocs.io/
MIT License
126 stars 51 forks source link

Compute wheel content hashes once #189

Open ralbertazzi opened 1 year ago

ralbertazzi commented 1 year ago

installer computes hashes over a wheel both on:

This isn't ideal when validating and installing gigantic wheels, such as this 2.1 GB torch distribution.

It would be great to keep content validation while avoiding computing hashes twice. I tried to implement it in a hackish way in https://github.com/python-poetry/poetry/pull/8027, but this should be solved inside installer itself.