Pass --target-platform with --variant-config to rattler-build - #6274
Open
mgorny wants to merge 5 commits into
Open
Pass --target-platform with --variant-config to rattler-build#6274mgorny wants to merge 5 commits into
--target-platform with --variant-config to rattler-build#6274mgorny wants to merge 5 commits into
Conversation
When calling `rattler-build` and we know the target platform, pass it explicitly via `--target-platform` even if `--variant-config` is being passed. Rattler-build does not support reading the target platform from variant config, and this is causing v1 recipes without `linux-64` support to fail: ``` │ ⚠ warning Setting 'target_platform' in a variant config file is not supported and will be ignored. Please use the '--target-platform' command-line flag to specify the target platform. ``` Signed-off-by: Michał Górny <mgorny@quansight.com>
Signed-off-by: Michał Górny <mgorny@quansight.com>
Signed-off-by: Michał Górny <mgorny@quansight.com>
Contributor
Author
|
Looks like the tests are failing because the test logic is processing all the recipes with CI support YAML for |
Contributor
Author
|
Uh, some tests also apparently pass junk there: |
Signed-off-by: Michał Górny <mgorny@quansight.com>
Contributor
Author
Okay, here the logic is actually buggy and it strips one underscore too few. |
mgorny
force-pushed
the
v1-target-platform
branch
from
June 26, 2026 15:09
c82972e to
b75f537
Compare
Remove the `win` os `skip`s from some v1 test recipes to fix problems with the test harness. The tests are being run against synthesized `.ci_support` support for three platforms (`linux-64, `osx-64` and `win-64`), irrespective of what platforms are supported by the recipe. Given that the `skip`s are not really crucial to the tests themselves, removing them is the simplest solution to avoid the problem. Signed-off-by: Michał Górny <mgorny@quansight.com>
Contributor
Author
|
I think all the remaining test failures are flakiness / network timeouts. |
jaimergp
reviewed
Jun 30, 2026
| target_platform_flags = ( | ||
| [] | ||
| if platform_arch is None or variant_config_flags | ||
| if platform_arch is None or platform_arch == "noarch" |
Member
There was a problem hiding this comment.
Suggested change
| if platform_arch is None or platform_arch == "noarch" | |
| if platform_arch in (None, "noarch") or variant_config_flags |
Better? Not sure what variant_config_flags is supposed to be checking here though.
Contributor
Author
There was a problem hiding this comment.
platform_arch in (None, "noarch")is what I've tried first butmypydoesn't seem to be able to cope with it.variant_config_flagsavoids passing--target-platformif we have a variant config. Removing this condition is the main point of this PR.
3 tasks
jaimergp
approved these changes
Jul 2, 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.
Description:
When calling
rattler-buildand we know the target platform, pass it explicitly via--target-platformeven if--variant-configis being passed. Rattler-build does not support reading the target platform from variant config, and this is causing v1 recipes withoutlinux-64support to fail:Additionally:
BaseRawURLto correctly infer filename from theci_support_*values, fixing platform/arch guessingskip: winfrom some v1 recipe tests where this breaks the assumptions made in the test harnessChecklist:
Cross-refs, links to issues, etc:
Fixes #6272