micropip
micropip copied to clipboard
double best_compatible_tag_index call ?
I think best_compatible_tag_index is called twice for each wheel in find_wheel;
Indeed, find_wheel calls it directly, but best_compatible_tag_index is also directly used by the various static method returning ProjectInfos, via the ProjectInfo._compatible_only(name, releases) -> ._compatible_wheels -> is_package_compatible -> best_compatible_tag_index(..) is not None.
I think it is likely possible to cache, or carry the tag index along and avoid computing it twice.
I think it is likely possible to cache,
caching sound good to me.