Assume a repository with two PRs on it (!1 and !2)
/main is protected by policy and requires build validation This build validation exires, once main has changed Build validation gets triggered on each new commit in the /feature branch
BUT Build validation does not restart itself, once it expired through changes in main.
So for all PRs had good build validaiton before a change in /main, have to be triggered again.
Is there a way to automatically trigger the build-validation of the other PRs?
This is by design. According to this ticket,
The expired builds will be requeued automatically when the ONLY policy keeping the PR from completing is an expired build.
When we implemented this feature we wanted to make sure that it didn’t create a chain reaction of builds getting re-queued so we intentionally only attempt one auto re-queue for now. If after autocomplete tries to requeue a build and it expires again (for example you have a build policy with immediate expiration when the target branch is updated), then auto complete won’t attempt to re-queue the build a second time.
To help you understand, you can refer to the following example. I have three PRs, merged from Branch1, Branch2, and Branch3 to main. Every PR has Auto-complete enabled.
To automatically trigger the build-validation of the other PRs, you can enable Auto-completed of your PR. But as mentioned above, if the build policy status of a PR becomes failed again, it will not be automatically queued.
As mentioned in doc Build validation,
Immediately when branch name is updated: This option is best for teams whose important branches have few changes. Teams working in busy development branches might find it disruptive to wait for a build every time the branch updates.
If there are many changes in your branches, it's suggested to use After <n> hours if <branch name> has been updated
option.