bazel_clang_tidy icon indicating copy to clipboard operation
bazel_clang_tidy copied to clipboard

Removed "no-sandbox" execution requirements for (partial) remote execution support

Open storypku opened this issue 3 years ago • 1 comments

We can pass .clang-tidy config around so that clang-tidy will always find it when running, thus removing the need for "no-sandbox" execution constraint.

storypku avatar Sep 09 '22 17:09 storypku

How does this solution work? iirc, files in filegroups are placed into a location that matches their label, however, this location does not match the execution root, where clang tidy is running from, where clang tidy will look for the configuration. How does it find the config? How did you test it? thanks

erenon avatar Sep 15 '22 14:09 erenon

image As can be seen from the sreenshot above, when passing //.clang_tidy_config as input to ctx.actions.run, If we run bazel-clang-tidy with --sandbox_debug, the .clang-tidy file is found at some parent path.

storypku avatar Sep 19 '22 02:09 storypku

Thanks!

erenon avatar Sep 21 '22 11:09 erenon