You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Runfiles support for nogo is further complicated by the fact that nogo runs as an "action". Bazel does not create the runfiles symlink farm for inputs in actions. In order for bazel to create a runfile symlink farm, a binary must be passed in as a tool. this means we would need to change how we propagate nogo down to the lower layers of the code.
Creating this issue to align on a direction.
The ultimately motivation for this was to expose the go_sdk to some analyzers that require it now after some upstream changes (in this case, our goimports analyzer broke after updating golang.org/x/tools due to it deciding it wanted to call go env at runtime: https://go-review.googlesource.com/c/tools/+/623296/7/internal/imports/fix.go#572).
The text was updated successfully, but these errors were encountered:
If an analyzer references any
data
attributes, those files are not propagated to the final binary when nogo runs.This is because nogo strips any runfiles and only plumbs the raw binary down: https://github.com/bazel-contrib/rules_go/blob/master/go/private/context.bzl#L662
Runfiles support for nogo is further complicated by the fact that nogo runs as an "action". Bazel does not create the runfiles symlink farm for
inputs
in actions. In order for bazel to create a runfile symlink farm, a binary must be passed in as atool
. this means we would need to change how we propagate nogo down to the lower layers of the code.Creating this issue to align on a direction.
The ultimately motivation for this was to expose the go_sdk to some analyzers that require it now after some upstream changes (in this case, our goimports analyzer broke after updating golang.org/x/tools due to it deciding it wanted to call
go env
at runtime: https://go-review.googlesource.com/c/tools/+/623296/7/internal/imports/fix.go#572).The text was updated successfully, but these errors were encountered: