Unbreak after 0.71.0 release of rules_rust - #40
Conversation
a53da8e to
ff61983
Compare
|
Thank you for approving the workflows! Sorry for being a dunce and not realizing the example directory had it's own |
Summary: The `0.71.0` release of `rules_rust` broke `gazelle_rust` by removing the deprecated `@rules_rust//crate_universe:extension.bzl` target. This commit updates `use_extension()` within MODULE.bazel to use the modern `extensions.bzl` target. This commit also takes the opportunity to update several bzlmod dependencies, which required resolving several clippy errors in `gazelle_rust_parser/src/lib.rs` that newly appeared after updating `rules_rust` to `0.71.0` Notes: - Updating `rules_rust` to `0.71.0` instead of `0.71.1` due to incompatibility between `rules_proto` and `rules_rust` - protocolbuffers/protobuf#28224 These changes are NOT AI generated, and I offer it to the gazelle_rust project under the terms of the APACHE license. - [fix] Fix use_extension() target for crate_universe in MODULE.bazel - [style] Fix clippy issues in `gazelle_rust_parser/src/lib.rs` - [build] Use golang version from `go.mod` - [build] Ignore cargo `/target` directories - [dep] Update bazel from `8.4.2` to `8.7.0` - [dep] Update `rules_shell` from `0.6.1` to `0.8.1` - [dep] Update `rules_go` from `0.59.0` to `0.61.1` - [dep] Update `gazelle` from `0.47.0` to `0.51.3` - [dep] Update `rules_rust` from `0.67.0` to `0.71.0` - [dep] Update `rules_rust_prost` from `0.67.0` to `0.71.0` - [dep] Update cargo packages in both root and `example` directories - [dep] Clean up `go.mod` with `bazel run @rules_go//go -- mod tidy -e` Test Plan: ```bash $> bazel build --config check //... INFO: Invocation ID: 36981488-710f-4ce8-8d3e-da03fecc2097 INFO: Analyzed 60 targets (0 packages loaded, 0 targets configured). INFO: Found 60 targets... INFO: Elapsed time: 0.184s, Critical Path: 0.00s INFO: 1 process: 108 action cache hit, 1 internal. INFO: Build completed successfully, 1 total action $> bazel test //... [ ... SNIP ... ] Executed 41 out of 41 tests: 41 tests pass. $> cd example $> bazel build //... INFO: Invocation ID: e7b360fd-7d64-4ad4-84fd-4735db416990 INFO: Analyzed 5 targets (79 packages loaded, 4020 targets configured). INFO: Found 5 targets... INFO: Elapsed time: 11.750s, Critical Path: 9.23s INFO: 130 processes: 1360 action cache hit, 25 internal, 105 processwrapper-sandbox. INFO: Build completed successfully, 130 total actions $> bazel test //... [ ... SNIP ... ] Executed 2 out of 2 tests: 2 tests pass. $> ```
Calsign
left a comment
There was a problem hiding this comment.
Thanks!
Sorry for being a dunce and not realizing the example directory had it's own MODULE.bazel peer files that needed to be updated as well, it wasn't obvious from the UI, and I only realized what was going on when I looked closer at the workflow file.
Perhaps I should add a CONTRIBUTING.md with, among other things, instructions for how to run the CI checks locally. I'm not sure how to make the UI more obvious. Are there other things that would be useful to have documented?
|
A CONTRIBUTING.md file would be great! Two smaller ideas that come to mind:
|
|
Thanks for the fast review! |
|
Thanks for the suggestions! I added a |
Summary:
The
0.71.0release ofrules_rustbrokegazelle_rustby removing thedeprecated
@rules_rust//crate_universe:extension.bzltarget.This commit updates
use_extension()within MODULE.bazel to use the modernextensions.bzltarget.This commit also takes the opportunity to update several bzlmod dependencies,
which required resolving several clippy errors in
gazelle_rust_parser/src/lib.rsthat newly appeared after updatingrules_rustto0.71.0Notes:
rules_rustto0.71.0instead of0.71.1due to incompatibilitybetween
rules_protoandrules_rustcratesis in a non-root module but has no lockfile" since rules_rust 0.71.1 protocolbuffers/protobuf#28224These changes are NOT AI generated, and I offer it to the gazelle_rust project
under the terms of the APACHE license.
gazelle_rust_parser/src/lib.rsgo.mod/targetdirectories8.4.2to8.7.0rules_shellfrom0.6.1to0.8.1rules_gofrom0.59.0to0.61.1gazellefrom0.47.0to0.51.3rules_rustfrom0.67.0to0.71.0rules_rust_prostfrom0.67.0to0.71.0exampledirectoriesgo.modwithbazel run @rules_go//go -- mod tidy -eTest Plan: