You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
bazel run @rules_rust//tools/rust_analyzer:gen_rust_project
in my Bazel/Rust project, the generated rust-project.json contains an entry for an code-generated crate, but the path in root_module of the crate entry does not exist. Removing the rust_project.json and re-running it doesn't fix it. I have tried disabling the disk_cache, but the command above still generates the wrong root_module.
The file /home/wvhulle/.cache/bazel/_bazel_wvhulle/2f024897ff0f2736b273e0e86d0d74ec/execroot/_main/bazel-out/k8-fastbuild/bin/otiv3/middleware_types/middleware_messages.lib.rs does not exist although the target can be build without problem.
I have tried to disable the disk cache completely, removing the disk cache at ~/.cache/bazel completely and also changing the location with --disk_cache=~/.cache/bazel_disk_cache.
It seems like the wrong path is generated pointing to a non-existing location in the cache. Sometimes it suddenly works, but often it is just broken and I don't understand why.
The text was updated successfully, but these errors were encountered:
I seem to make some progress if remove all disk cache options from .bazelrc: common --disk_cache=~/.cache/bazel_disk_cache. It seems like there is a bug that causes the rust-project.json not to detect the usage of an alternative disk_cache. When I don't specify the cache and start from a clean state, things seem to work at first sight.
When I run
in my Bazel/Rust project, the generated
rust-project.json
contains an entry for an code-generated crate, but the path inroot_module
of the crate entry does not exist. Removing therust_project.json
and re-running it doesn't fix it. I have tried disabling the disk_cache, but the command above still generates the wrongroot_module
.This is an example output
The file
/home/wvhulle/.cache/bazel/_bazel_wvhulle/2f024897ff0f2736b273e0e86d0d74ec/execroot/_main/bazel-out/k8-fastbuild/bin/otiv3/middleware_types/middleware_messages.lib.rs
does not exist although the target can be build without problem.I have tried to disable the disk cache completely, removing the disk cache at
~/.cache/bazel
completely and also changing the location with--disk_cache=~/.cache/bazel_disk_cache
.It seems like the wrong path is generated pointing to a non-existing location in the cache. Sometimes it suddenly works, but often it is just broken and I don't understand why.
The text was updated successfully, but these errors were encountered: