Skip to content

Bazel 7 "dangling symbolic link" flake #13444

@dbolduc

Description

@dbolduc
ERROR: /h/.cache/bazel/_bazel_root/eab0d61a99b6696edb3d2aff87b585e8/external/io_opentelemetry_cpp/sdk/src/common/BUILD:6:11: output 'external/io_opentelemetry_cpp/sdk/src/common/_virtual_includes/random/src/common/random.h' is a dangling symbolic link
ERROR: /h/.cache/bazel/_bazel_root/eab0d61a99b6696edb3d2aff87b585e8/external/io_opentelemetry_cpp/sdk/src/trace/BUILD:6:11: output 'external/io_opentelemetry_cpp/sdk/src/trace/_virtual_includes/trace/src/trace/span.h' is a dangling symbolic link
...etc...
ERROR: /h/.cache/bazel/_bazel_root/eab0d61a99b6696edb3d2aff87b585e8/external/io_opentelemetry_cpp/api/BUILD:13:11: Symlinking virtual headers for api failed: not all outputs were created or valid
ERROR: /h/.cache/bazel/_bazel_root/eab0d61a99b6696edb3d2aff87b585e8/external/io_opentelemetry_cpp/sdk/BUILD:6:11: Symlinking virtual headers for headers failed: not all outputs were created or valid

We only start seeing this flake when we upgrade to Bazel 7, which comes with "Build without bytes" enabled. This other issue seems related: bazelbuild/bazel#19143

In the 4 or 5 times we have seen the flake, the failure has always been with the @io_opentelemetry_cpp repo. I do not know what makes it special. My guess is their use of include_prefix, e.g.:

https://github.com/open-telemetry/opentelemetry-cpp/blob/c4f39f2be8109fd1a3e047677c09cf47954b92db/sdk/src/trace/BUILD#L10

Metadata

Metadata

Assignees

No one assigned

    Labels

    cpp: flakeA test with false positives (failures that are not interesting)type: cleanupAn internal cleanup or hygiene concern.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions