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

unexpected keyword 'ctx', for call to method configure_features #1090

Closed
cstrahan opened this issue Aug 14, 2019 · 3 comments
Closed

unexpected keyword 'ctx', for call to method configure_features #1090

cstrahan opened this issue Aug 14, 2019 · 3 comments

Comments

@cstrahan
Copy link

I'm getting the following error when I try to sync my *.cc files:

ERROR: /home/cstrahan/.cache/bazel/_bazel_cstrahan/0e3896d6d23d3761a1e0a1ef1f9e1eac/external/local_config_cc/BUILD:45:1: in @intellij_aspect//:intellij_info_bundled.bzl%intellij_info_aspect aspect on cc_toolchain_suite rule @local_config_cc//:toolchain: 
Traceback (most recent call last):
	File "/home/cstrahan/.cache/bazel/_bazel_cstrahan/0e3896d6d23d3761a1e0a1ef1f9e1eac/external/local_config_cc/BUILD", line 45
		@intellij_aspect//:intellij_info_bundled.bzl%intellij_info_aspect(...)
	File "/home/cstrahan/.cache/bazel/_bazel_cstrahan/0e3896d6d23d3761a1e0a1ef1f9e1eac/external/intellij_aspect/intellij_info_bundled.bzl", line 54, in _aspect_impl
		intellij_info_aspect_impl(target, ctx, semantics)
	File "/home/cstrahan/.cache/bazel/_bazel_cstrahan/0e3896d6d23d3761a1e0a1ef1f9e1eac/external/intellij_aspect/intellij_info_impl.bzl", line 886, in intellij_info_aspect_impl
		collect_c_toolchain_info(target, ctx, semantics, ide_info, <2 more arguments>)
	File "/home/cstrahan/.cache/bazel/_bazel_cstrahan/0e3896d6d23d3761a1e0a1ef1f9e1eac/external/intellij_aspect/intellij_info_impl.bzl", line 453, in collect_c_toolchain_info
		cc_common.configure_features(ctx = ctx, cc_toolchain = cpp_tool..., <2 more arguments>)
unexpected keyword 'ctx', for call to method configure_features(cc_toolchain, requested_features = [], unsupported_features = []) of 'cc_common'

Any idea what's going wrong? (My project builds successfully via bazel)

$ bazel version
Build label: 0.24.1
Build target: bazel-out/k8-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Tue Apr 2 16:29:26 2019 (1554222566)
Build timestamp: 1554222566
Build timestamp as int: 1554222566
@thundergolfer
Copy link

Can report the same error:

$ bazel version
Starting local Bazel server and connecting to it...
Build label: 0.24.0- (@non-git)
Build target: bazel-out/darwin-opt/bin/src/main/java/com/google/devtools/build/lib/bazel/BazelServer_deploy.jar
Build time: Sat Apr 27 19:45:09 2019 (1556394309)
Build timestamp: 1556394309
Build timestamp as int: 1556394309

@jin
Copy link
Member

jin commented Aug 21, 2019

Related issue: bazelbuild/bazel#7793

It looks like the plugin was modified to support this feature introduced in Bazel 0.27. If you cannot update to Bazel 0.27 yet, try updating to Bazel 0.25 and use the flag --incompatible_require_ctx_in_configure_features.

@jin
Copy link
Member

jin commented Sep 26, 2019

Closing as wontfix, please use the above workarounds.

@jin jin closed this as completed Sep 26, 2019
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

3 participants