Skip to content

incompatible_strict_conflict_checks #16729

@tjgq

Description

@tjgq

Turning on this flag forbids the creation of nested artifacts (where one is a prefix of the other). For example, a regular artifact referring to a file inside a tree artifact, or a tree artifact referring to a subdirectory of another tree artifact. They are currently allowed as long as they're both produced by the same action.

When the flag is flipped, nested artifacts will produce an error:

One of the output paths 'blaze-out/k8-fastbuild/bin/foo' (belonging to //:foo) and 'blaze-out/k8-fastbuild/bin/foo/bar' (belonging to //:foo) is a prefix of the other. These actions cannot be simultaneously present; please rename one of the output files or build just one of them

Nested artifacts create unnecessary complications for sandboxing and input prefetching, and we would prefer not to support them. To migrate, rules that consume the inner artifact should be modified to consume the outer artifact instead.

Metadata

Metadata

Assignees

No one assigned

    Labels

    breaking-change-7.0Incompatible flags to be flipped in Bazel 7.0incompatible-changeIncompatible/breaking changemigration-readyIncompatible flag is ready for migration with Bazel rolling releases or Bazel@last_greentype: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions