Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Share a single Index across resolutions #906

Merged
merged 1 commit into from
Jan 16, 2024
Merged

Conversation

charliermarsh
Copy link
Member

Summary

This PR uses a single Index that's shared between the top-level resolver and any sub-resolutions happen in the course of that top-level resolution (namely, to resolve build dependencies for any source distributions).

In theory it's an optimization, since (e.g.) if we have two packages that both need the flit-core build system, and we attempt to build them both at once, we'll only fetch its metadata once, and share it across the two resolutions. In practice, I haven't been able to get this to show up in benchmarks. I suspect you'd need a lot of source distributions for it to matter... Though it may still be worth doing, it strikes me as a cleaner design.

Closes #200.

Closes #541.

@charliermarsh charliermarsh requested a review from konstin January 13, 2024 03:45
@charliermarsh charliermarsh changed the base branch from main to charlie/index January 13, 2024 03:46
@charliermarsh charliermarsh added the internal A refactor or improvement that is not user-facing label Jan 13, 2024
@charliermarsh charliermarsh force-pushed the charlie/index branch 3 times, most recently from dbb7696 to 8e7fbea Compare January 16, 2024 03:33
@charliermarsh charliermarsh changed the base branch from charlie/index to main January 16, 2024 05:24
@charliermarsh charliermarsh enabled auto-merge (squash) January 16, 2024 05:37
@charliermarsh charliermarsh merged commit 2f8f126 into main Jan 16, 2024
3 checks passed
@charliermarsh charliermarsh deleted the charlie/share branch January 16, 2024 05:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
internal A refactor or improvement that is not user-facing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Forward partial resolution to source dist building Track and share resolver's in-memory index globally
3 participants