Fix performance regression in unzip of local wheels#19636
Closed
zanieb wants to merge 1 commit into
Closed
Conversation
Member
Author
|
The proper solution, imo, is astral-sh/rs-async-zip#41 |
zanieb
added a commit
to astral-sh/rs-async-zip
that referenced
this pull request
Jun 1, 2026
zanieb
pushed a commit
that referenced
this pull request
Jun 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #19635
I reproduced the issue over increasing target sizes
0.11.140.11.151,0002500.045s0.048s1.1x3,0007500.117s0.147s1.3x10,0002,5000.379s0.844s2.2x30,0007,5001.16s11.42s9.8x100,00025,0003.59s213.5s59.5xThe issue appears to not be build, e.g.,
uv build --wheelwas no affected, but unpacking the wheel into the cache.The root cause is that cloning the zip reader is really expensive in
rs-async-zip, unlike the synczipcrate.Here are the results for 100k files, including after this fix.
0.11.143.71s28.59s38.41s3.17s42.04s0.11.153m34s30.84s251.03s1755.53s1367.60s3.07s27.03s35.09s3.57s39.95s