Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Pass select tags from target to generated actions as execution requirements #187

Closed
SrodriguezO opened this issue Jun 12, 2019 · 5 comments · Fixed by #190
Closed

Pass select tags from target to generated actions as execution requirements #187

SrodriguezO opened this issue Jun 12, 2019 · 5 comments · Fixed by #190

Comments

@SrodriguezO
Copy link
Collaborator

SrodriguezO commented Jun 12, 2019

The tags attribute lets us tell Bazel to treat certain actions specially; for example, the "no-remote" tag will inform Bazel that an action should not be run remotely even if it otherwise would.

Unfortunately, Bazel doesn't automatically propagate tags from a rule to the actions the rule generates. We need to explicitly do this propagation in our rule implementations.

See: bazelbuild/bazel#7766

@SrodriguezO
Copy link
Collaborator Author

I'm happy to take this issue sometime this week.

@SrodriguezO SrodriguezO changed the title Pass tags attribute to generated Actions Pass select tags from target to generated actions as execution requirements Jun 13, 2019
@SrodriguezO
Copy link
Collaborator Author

It appears that this will be taken care of upstream in the future: https://docs.google.com/document/d/1X2GtuuNT6UqYYOK5lJWQEdPjAgsbdB3nFjjmjso-XHo/edit?ts=5ca70ed0#

I'll still open a PR with a fix for higherkindness/rules_scala though. This way we'll get expected behavior sooner than later. For future consistency, I'll only propagate the labels specified in the design proposal linked above.

@ishikhman
Copy link

ishikhman commented Jun 13, 2019

@SrodriguezO I've just created PR for Bazel yesterday ;) bazelbuild/bazel#8612

@SrodriguezO
Copy link
Collaborator Author

Ah woops, I totally missed that. Thanks @ishikhman! :)

I'll leave this issue open though; I imagine the fix to bazelbuid/bazel will go out in a future release? I'd prefer to not block the fix to higherkindness/rules_scala on upgrading Bazel.

@ishikhman
Copy link

Ah woops, I totally missed that. Thanks @ishikhman! :)

I'll leave this issue open though; I imagine the fix to bazelbuid/bazel will go out in a future release? I'd prefer to not block the fix to higherkindness/rules_scala on upgrading Bazel.

Yes, it will be released somewhere in July.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants