fix: Remove spurious emulation warning when just locking#5723
Merged
wolfv merged 2 commits intoprefix-dev:mainfrom Mar 26, 2026
Merged
fix: Remove spurious emulation warning when just locking#5723wolfv merged 2 commits intoprefix-dev:mainfrom
wolfv merged 2 commits intoprefix-dev:mainfrom
Conversation
wolfv
approved these changes
Mar 26, 2026
Member
|
Thank you @kilian-hu |
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
This PR fixes a bug that causes a spurious warning like this:
This warning makes sense when a Python interpreter is actually run but it also happens when simply running
pixi lockin a fresh project with thispixi.tomlAFAIU this is because the function
best_platform_with_currentalways checks if it should emit such a warning even if that function is also used in the resolution logic where no Python interpreter is actually run so the warning does not really make sense in that case. So the logic for emitting this warning should be pulled out of that function and re-added where it makes sense. The function currently mixes multiple purposes like this:pixi/crates/pixi_core/src/workspace/environment.rs
Lines 124 to 149 in c318ac1
How Has This Been Tested?
I'm on macOS arm64. With the above
pixi.tomland my changes I tried the following cases. It's important to always clear the.pixi/one-time-messages/directory to truthfully test this.pixi lockshould not give warning anymore.pixi install --environment osx-arm64-devshould not give warning anymore.pixi install --environment osx-64-devgives legitimate warning.pixi install --environment linux-64-devgives legitimate error.AI Disclosure
Tools: Claude Code with Opus 4.6
Checklist:
schema/model.py.