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

failure in bazel run //local:create_gopath (cwd='src') #650

Closed
wideglide opened this issue Jul 5, 2019 · 3 comments
Closed

failure in bazel run //local:create_gopath (cwd='src') #650

wideglide opened this issue Jul 5, 2019 · 3 comments

Comments

@wideglide
Copy link

I ran into the same issue with both the v1.3.0 and v1.2.1 releases, running local/install_deps.bash on Ubuntu 18.04 I get the following error:

Running: bazel run //local:create_gopath (cwd='src')
| Extracting Bazel installation...
| Starting local Bazel server and connecting to it...
| Loading:
| Loading: 0 packages loaded
| Loading: 0 packages loaded
| Loading: 0 packages loaded
| Analyzing: target //local:create_gopath (1 packages loaded, 0 targets configured)
| Analyzing: target //local:create_gopath (7 packages loaded, 17 targets configured)
| Analyzing: target //local:create_gopath (7 packages loaded, 17 targets configured)
| Analyzing: target //local:create_gopath (7 packages loaded, 17 targets configured)
| Analyzing: target //local:create_gopath (7 packages loaded, 17 targets configured)
| ERROR: /home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/BUILD.bazel:62:1: in go_context_data rule @io_bazel_rules_go//:go_context_data:
| Traceback (most recent call last):
|       File "/home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/BUILD.bazel", line 62
|               go_context_data(name = 'go_context_data')
|       File "/home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/go/private/context.bzl", line 396, in _go_context_data_impl
|               cc_common.configure_features(cc_toolchain = cc_toolchain, reque..., ...)
| Incompatible flag --incompatible_require_ctx_in_configure_features has been flipped, and the mandatory parameter 'ctx' of cc_common.configure_features is missing. Please add 'ctx' as a named parameter. See https://github.com/bazelbuild/bazel/issues/7793 for details.
| ERROR: Analysis of target '//local:create_gopath' failed; build aborted: Analysis of target '@io_bazel_rules_go//:go_context_data' failed; build aborted
| INFO: Elapsed time: 48.634s

I tried adding the ctx parameter as suggested in the bazel issue, but then I get a different error:

ERROR: /home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/BUILD.bazel:62:1: in go_context_data rule @io_bazel_rules_go//:go_context_data:
Traceback (most recent call last):
        File "/home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/BUILD.bazel", line 62
                go_context_data(name = 'go_context_data')
        File "/home/localuser/.cache/bazel/_bazel_localuser/de65168dfbbea5a8f0776c717b698172/external/io_bazel_rules_go/go/private/context.bzl", line 396, in _go_context_data_impl
                cc_common.configure_features(ctx = ctx, cc_toolchain = cc_toolc..., <2 more arguments>)
go_context_data has to declare 'CppConfiguration' as a required fragment in target configuration in order to access it.
ERROR: Analysis of target '//local:create_gopath' failed; build aborted: Analysis of target '@io_bazel_rules_go//:go_context_data' failed; build aborted
INFO: Elapsed time: 0.754s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (12 packages loaded, 135 targets configured)
FAILED: Build did NOT complete successfully (12 packages loaded, 135 targets configured)

Not sure where to go from here?

@inferno-chromium
Copy link
Collaborator

can you clone tip-of-tree (trunk)
git clone https://github.com/google/clusterfuzz.git
and see if it works. ?

@inferno-chromium
Copy link
Collaborator

Can't reproduce on 18.10 on compute engine bot. Is your bazel version current ? Like 0.27.1 or higher ?

@wideglide
Copy link
Author

cloning from master works! I should have tried that first and just ignored the documentation.
and my bazel version is 0.27.1

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

No branches or pull requests

2 participants