-
Notifications
You must be signed in to change notification settings - Fork 261
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
Remove ctx.resolve_tools
in favor of ctx.actions.run(executable = …)
and ctx.actions.run(tools = ...)
.
#2438
Conversation
ed3ee93
to
02390d6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for this @tjgq!
…...)` and `ctx.actions.run(tools = ...)`. By passing the files_to_run for a tool into the `executable` or `tools` argument to `ctx.actions.run` or `ctx.actions.run_shell`, it's no longer necessary to pass the return values of `ctx.resolve_tools` into the `inputs` and `input_manifests` arguments. Each struct field of the AppleMacToolsToolchainInfo and AppleXPlatToolsToolchainInfo providers previously populated with the return values of `ctx.resolve_tools` is now populated with the files_to_run for the respective tool. The `resolved_` prefix is removed from field and variable names; in addition to it no longer making sense, this change provides proof that all usages have been audited. This lets us retire the `ctx.resolve_tools` API in a future Bazel version.
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
We should list this as a breaking change in the releases i think, it broke some downstream rules since the |
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
rules_apple 3.5.0 broke `resolved_*` tools from `AppleMacToolchainInfo` (bazelbuild/rules_apple#2438) This sets the new minimum supported version for the next rules_ios release to 3.5.0.
That's not public API, right? I think we are free to modify that without any mention. |
Yeah you're right. Thought it was in providers.bzl but doesn't look like it |
……)` and `ctx.actions.run(tools = ...)`. (bazelbuild#2438) By passing the files_to_run for a tool into the `executable` or `tools` argument to `ctx.actions.run` or `ctx.actions.run_shell`, it's no longer necessary to pass the return values of `ctx.resolve_tools` into the `inputs` and `input_manifests` arguments. Each struct field of the AppleMacToolsToolchainInfo and AppleXPlatToolsToolchainInfo providers previously populated with the return values of `ctx.resolve_tools` is now populated with the files_to_run for the respective tool. The `resolved_` prefix is removed from field and variable names; in addition to it no longer making sense, this change provides proof that all usages have been audited. This lets us retire the `ctx.resolve_tools` API in a future Bazel version.
By passing the files_to_run for a tool into the
executable
ortools
argument toctx.actions.run
orctx.actions.run_shell
, it's no longer necessary to pass the return values ofctx.resolve_tools
into theinputs
andinput_manifests
arguments.Each struct field of the AppleMacToolsToolchainInfo and AppleXPlatToolsToolchainInfo providers previously populated with the return values of
ctx.resolve_tools
is now populated with the files_to_run for the respective tool.The
resolved_
prefix is removed from field and variable names; in addition to it no longer making sense, this change provides proof that all usages have been audited.This lets us retire the
ctx.resolve_tools
API in a future Bazel version.