feat: Prefilter Shard Records on Python Minor Version#4214
Open
jjerphan wants to merge 13 commits intomamba-org:mainfrom
Open
feat: Prefilter Shard Records on Python Minor Version#4214jjerphan wants to merge 13 commits intomamba-org:mainfrom
jjerphan wants to merge 13 commits intomamba-org:mainfrom
Conversation
2a15510 to
02817f8
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4214 +/- ##
==========================================
- Coverage 53.65% 52.72% -0.93%
==========================================
Files 239 240 +1
Lines 29349 29510 +161
Branches 3122 3151 +29
==========================================
- Hits 15747 15559 -188
- Misses 13599 13948 +349
Partials 3 3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
9c47b94 to
51f2501
Compare
11 tasks
afb6f6a to
55f2328
Compare
cc572b0 to
9e2aa2b
Compare
9b1f296 to
5a2da95
Compare
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Such as: ``` warning libmamba Failed to parse field 'noarch' (msgpack type=1) in shard package record for 'tensorboard-2.1.1-py38_0.tar.bz2': Expected STR or BIN type for string conversion. This field will be ignored. ``` Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
0a72888 to
ea75e1d
Compare
jjerphan
commented
Apr 2, 2026
| } | ||
|
|
||
| std::optional<specs::Version> | ||
| installed_python_minor_for_prefix(const fs::u8path& target_prefix) |
Member
Author
There was a problem hiding this comment.
Are there utilities we could reuse instead?
Member
Author
There was a problem hiding this comment.
PrefixData could be reused, but this would be much more costly (because it parses all the installed packages JSON and convert them to PackageInfo). We only need one specs::Version here.
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
3f4ee57 to
fb64ec3
Compare
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
Signed-off-by: Julien Jerphanion <git@jjerphan.xyz>
d388860 to
a4e0425
Compare
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.
Description
Comes after #4187 and #4220.
Since the minor versions
pythonis pinned in users' environments, we can prefilter records in shards using it to only selected relevant builds.This definitely eases the installation of packages depending on
python, by reducing the number of clauses within the solver and thus the time spent and RAM used resolving the environments. For instance forpyarrow, it reduces the time spent by 5 and the memory footprint by 20.If
pythonis not installed, we first try to prefilter builds depending on a fallback minor version (python 3.14proposed), before potentially retrying without (current behavior) if this fallback minor version cannot be used.Type of Change
Checklist
pre-commit run --alllocally in the source folder and confirmed that there are no linter errors.