Skip to content

Conversation

shaldengeki
Copy link
Contributor

This upgrades the version of Gazelle to HEAD. I need this, because I'd like to write tests in #3057 against a setup using bzlmod, but our current version doesn't support that:

$ bazel test //... FAIL: //python:python_test_directive_python_generate_proto_module_protobuf (Exit 1) (see /home/charles/.cache/bazel/_bazel_charles/25da5a3f5a375d8b77b073daf0c17156/execroot/_main/bazel-out/k8-fastbuild/testlogs/python/python_test_directive_python_generate_proto_module_protobuf/test.log) INFO: From Testing //python:python_test_directive_python_generate_proto_module_protobuf: ==================== Test output for //python:python_test_directive_python_generate_proto_module_protobuf: --- FAIL: TestGazelleBinary (0.00s) --- FAIL: TestGazelleBinary/directive_python_generate_proto_module_protobuf (0.01s) python_test.go:169: expected gazelle exit code: 0 got: 1 python_test.go:179: expected gazelle stderr: got: gazelle: -repo_root not specified, and WORKSPACE cannot be found: file does not exist python_test.go:144: "" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf/BUILD" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf/MODULE.bazel" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf/README.md" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf/foo.proto" exists python_test.go:144: "/directive_python_generate_proto_module_protobuf/test.yaml" exists FAIL 

(note the MODULE.bazel in the above logs. That's the test I'm adding covering bzlmod support.)

With this change, the test works:

$ bazel test //... # ... Executed 70 out of 71 tests: 71 tests pass. 
@shaldengeki
Copy link
Contributor Author

shaldengeki commented Jul 5, 2025

Hmm, well, this is a bummer. Looks like newer versions of Gazelle rely on go 1.20.x: https://buildkite.com/bazel/rules-python-python/builds/12038/steps/canvas?sid=0197dcca-d714-4faa-96ff-0d4a4df34557

So this requires a bump of that. Lemme see if that's not too painful - I'm hoping not.

@shaldengeki
Copy link
Contributor Author

Hmmmmmm.

https://buildkite.com/bazel/rules-python-python/builds/12039/steps/canvas?sid=0197dcd2-e4e8-4781-957c-78b99345b5b3

external\gazelle++go_deps+com_github_dougthor42_go_tree_sitter\iter.go:17:18: undefined: Node 

iiiinteresting.

@shaldengeki
Copy link
Contributor Author

Ah, I guess @dougthor42 is already working on this here: #2962

@shaldengeki
Copy link
Contributor Author

Gonna close this while I figure out what to do in #3057.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant