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 x/tools to 0.1.8 #3030

Closed
chressie opened this issue Dec 16, 2021 · 0 comments · Fixed by #3031
Closed

Update x/tools to 0.1.8 #3030

chressie opened this issue Dec 16, 2021 · 0 comments · Fixed by #3031

Comments

@chressie
Copy link
Contributor

What version of rules_go are you using?

Current master branch (34a808c)

What version of gazelle are you using?

n/a

What version of Bazel are you using?

4.2.2

Does this issue reproduce with the latest releases of all the above?

Yes.

What operating system and processor architecture are you using?

n/a

Any other potentially useful information about your toolchain?

Using go1.18beta1.

What did you do?

Define a nogo check + use of go1.18beta1.

Basically follow the steps in https://github.com/bazelbuild/rules_go/blob/master/go/nogo.rst and use go_register_toolchains(version = "1.18beta1").

What did you expect to see?

Succeeding build.

What did you see instead?

Build fails with:

analyzer "printf" failed: analysis skipped due to type-checking error: foo.go:4:2: could not import fmt (cannot import "fmt" (unstable iexport format version 2, just rebuild compiler and std library), export data is newer version - update tool)

The issue is that Go 1.18 bumps the version number in export data. The x/tools version that is currently used by rules_go doesn't support that yet and needs to be updated.

@chressie chressie changed the title Update x/tools to latest version Update x/tools to 0.1.8 Dec 16, 2021
chressie added a commit to chressie/rules_go that referenced this issue Dec 16, 2021
Ran the following commands:

bazel build go/tools/releaser
sed -i /org_golang_x_tools-public-visibility.patch/d go/private/repositories.bzl
rm third_party/org_golang_x_tools-public-visibility.patch
bazel-bin/go/tools/releaser/releaser_/releaser upgrade-dep org_golang_x_tools
robfig pushed a commit that referenced this issue Dec 16, 2021
Ran the following commands:

bazel build go/tools/releaser
sed -i /org_golang_x_tools-public-visibility.patch/d go/private/repositories.bzl
rm third_party/org_golang_x_tools-public-visibility.patch
bazel-bin/go/tools/releaser/releaser_/releaser upgrade-dep org_golang_x_tools
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 a pull request may close this issue.

1 participant