-
Notifications
You must be signed in to change notification settings - Fork 64
Closed
Description
The current master (9e9bfc5) code doesn't work.
❯ bazel build //example/... --aspects clang_tidy/clang_tidy.bzl%clang_tidy_aspect --output_groups=report
INFO: Analyzed 5 targets (3 packages loaded, 31 targets configured).
INFO: Found 5 targets...
INFO: Elapsed time: 0.121s, Critical Path: 0.04s
INFO: 7 processes: 2 internal, 5 processwrapper-sandbox.
INFO: Build completed successfully, 7 total actions
If checked into (0b86881), it works fine.
❯ bazel build //example/... --aspects clang_tidy/clang_tidy.bzl%clang_tidy_aspect --output_groups=report
INFO: Analyzed 4 targets (1 packages loaded, 8 targets configured).
ERROR: /home/xxx/Workspace/bazel_clang_tidy/example/BUILD:1:11: Run clang-tidy on example/lib.cpp failed: (Exit 1): clang_tidy failed: error executing ClangTidy command (from target //example:lib) bazel-out/k8-fastbuild/bin/clang_tidy/clang_tidy clang-tidy bazel-out/k8-fastbuild/bin/example/bazel_clang_tidy_example/lib.cpp.lib.clang-tidy.yaml .clang-tidy --export-fixes ... (remaining 19 arguments skipped)
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
8987 warnings generated.
/home/xxx/.cache/bazel/_bazel_xxx/90ed30fac4a9b2ab2f943ec475e6d263/sandbox/processwrapper-sandbox/29/execroot/_main/example/lib.cpp:4:43: error: the parameter 'name' is copied for each invocation but only used as a const reference; consider making it a const reference [performance-unnecessary-value-param,-warnings-as-errors]
4 | std::string lib_get_greet_for(std::string name)
| ^
| const &
Suppressed 8986 warnings (8986 in non-user code).
Use -header-filter=.* to display errors from all non-system headers. Use -system-headers to display errors from system headers as well.
1 warning treated as error
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 0.681s, Critical Path: 0.57s
INFO: 7 processes: 4 internal, 3 processwrapper-sandbox.
ERROR: Build did NOT complete successfully
BTW, Bazel 6.5 version doesn't work.
# Bazel 6 output errorError: 'CompilationContext' value has no field or method 'external_includes'
Error: 'CompilationContext' value has no field or method 'external_includes'
Metadata
Metadata
Assignees
Labels
No labels