Ability to silence warning "Directory artifact package crosses package boundary"
- Dominant language
- Java
- Stars
- 25.8k
- Forks
- 4.6k
- Avg merge
- 2d 20h
- Merged PRs (30d)
- 72
Description
### Description of the feature request:
We are getting a lot of spam in our build logs from Bazel, with this warning:
"Directory artifact package crosses package boundary into package rooted at ..."
It would be good to provide support for disabling this warning, to reduce the spam. Alternatively drop the warning altogether, or if the warning is truly important, make it an error.
More discussion: https://bazelbuild.slack.com/archives/CA31HN1T3/p1768566694334739
### Which category does this issue belong to?
Core
### What underlying problem are you trying to solve with this feature?
Reduce spam in the build logs so I can more easily see real issues.
### Which operating system are you running Bazel on?
Ubuntu 24.04
### What is the output of `bazel info release`?
release 8.5.1
### If `bazel info release` returns `development version` or `(@non-git)`, tell us how you built Bazel.
_No response_
### What's the output of `git remote get-url origin; git rev-parse HEAD` ?
```text
```
### Have you found anything relevant by searching the web?
_No response_
### Any other information, logs, or outputs that you want to share?
_No response_
Contributor guide
Research direction
Start by reproducing the "Directory artifact package crosses package boundary" warning with Bazel 8.5.1 on Ubuntu 24.04 and inspect how the warning is emitted. Review the linked Slack discussion to determine whether suppression, removal, or escalation is intended; done means the selected behavior reduces log spam and is covered by appropriate validation.
Written by the indexing model from the issue text.
Assessment
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100