_validation generated by aspects silently do not execute through a transition unlike those added through regular rules
- Dominant language
- Java
- Stars
- 25.8k
- Forks
- 4.6k
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 75
Description
### Description of the bug:
If you add a _validation stage using a rule then when you transition the _validation is run within the context of the transition. If however you are using an aspect to add the _validation stage the even though bazel aquery shows the four expected validation, only three are run.
### Which category does this issue belong to?
Core
### What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
`bazel build //...` on this should produce 4 validation errors. Instead we see 3 because we are missing the validation in the transitioned aspect.
[validation_tansitions.zip](https://github.com/user-attachments/files/16266564/validation_tansitions.zip)
### Which operating system are you running Bazel on?
windows/any
### What is the output of `bazel info release`?
release 7.2.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` ?
_No response_
### If this is a regression, please try to identify the Bazel commit where the bug was introduced with bazelisk --bisect.
_No response_
### Have you found anything relevant by searching the web?
https://github.com/bazelbuild/bazel/issues/19636
My original question
https://groups.google.com/g/bazel-discuss/c/TCo0msh1My4/m/V3ET0eXKAwAJ
More questions on transitions:
https://groups.google.com/g/bazel-discuss/c/euTqZeYR8hs/m/k-bcNFBdAQAJ
### Any other information, logs, or outputs that you want to share?
[aquery_of_actions.txt](https://github.com/user-attachments/files/16266817/aquery_of_actions.txt)
Contributor guide
Research direction
Start with the attached validation_tansitions.zip reproduction and run `bazel build //...` to compare the three reported validation errors with the four expected ones. Read the generated validation actions in aquery_of_actions.txt and trace how aspect-added validations are handled during transitions. Done means the reproduction reports all four validation errors, including the transitioned aspect validation.
Written by the indexing model from the issue text.
Assessment
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100