aspect-build / aspect-build/rules_lint
[Bug]: Rustfmt check doesn't work with v2.0
- Dominant language
- Starlark
- Stars
- 154
- Forks
- 125
- Avg merge
- 3d 21h
- Merged PRs (30d)
- 20
Description
### What happened?
Running `bazel run //:format.check` with Rust enabled in the repository doesn't work on latest version (2.0.0-rc0):
```
Formatting Rust with rustfmt...
Loading: 0 packages loaded
ERROR: Error while parsing 'let scope = set(--check [a bunch of files listed])': syntax error at '- - check'
Failed to perform `bazel query` command.
Formatted Rust in 0m0.185s
```
### Version
Development (host) and target OS/architectures:
Output of `bazel --version`: 8.2.1
Version of the Aspect rules, or other relevant rules from your
`WORKSPACE` or `MODULE.bazel` file: 2.0.0-rc0
Language(s) and/or frameworks involved:
Rust (with rules_rust)
### How to reproduce
```shell
Try using rustfmt in checking mode through aspect_rules_lint.
```
### Any other information?
I have removed some specifics from the error to hide some company IP. Please let me know if there's something else missing that you need!
Contributor guide
Research direction
Start by reproducing the failure with `bazel run //:format.check` using Rust enabled and the reported rules version 2.0.0-rc0. Trace the `format.check` path in aspect_rules_lint and compare its handling of rustfmt checking mode with the Bazel 8.2.1 error; done means the command completes successfully and reports Rust formatting correctly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100