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

update buck2 samples using https://github.com/facebook/buck2/pull/826 #372

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

nlopezgi
Copy link
Contributor

  • Use constraints to select action keys for tests on RE only
  • Use --target-platforms to select platform on the command line
  • Remove RE only attrs from targets

@nlopezgi nlopezgi force-pushed the nlopezgi/cleanUpBuck2Samples branch from 7c7b376 to a12e83b Compare February 26, 2025 18:08
@nlopezgi nlopezgi changed the title update buck2 samples according to recommendations in rust2 sample PR update buck2 samples using https://github.com/facebook/buck2/pull/826 Feb 26, 2025
@@ -45,6 +45,7 @@ def _platforms(ctx):
return [
DefaultInfo(),
ExecutionPlatformRegistrationInfo(platforms = [platform]),
PlatformInfo(label = str(name), configuration = configuration),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as before. Plus should this even be part of this PR?

Copy link
Contributor Author

@nlopezgi nlopezgi Mar 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without these lines the builds fail with the following error:

Expected `root//platforms:remote_platform` to be a `platform()` target, but it had no `PlatformInfo` provider.

Without the str(..) call this fails with error:

error: Type of parameter `label` doesn't match, expected `str`, actual `target_label (repr: root//platforms:remote_platform)`

@nlopezgi nlopezgi force-pushed the nlopezgi/cleanUpBuck2Samples branch from 23c308b to 6576ccc Compare March 3, 2025 14:45
@nlopezgi nlopezgi requested a review from TheGrizzlyDev March 3, 2025 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants