Skip to content

Commit 20886ff

Browse files
Jacob Nowjackbazel-io
authored andcommitted
Fix transitive deps crashes due to IllegalStateException (bazelbuild#29289)
### Description This adds a needed `valuesMissing()` guard to fix rare crashes with `IllegalStateException` when evaluating `TransitiveTargetKey` nodes whose transitive closures include rules with aspects. ### Motivation Fixes bazelbuild#29280 ### Build API Changes No ### Checklist - [ ] I have added tests for the new use cases (if any). - [ ] I have updated the documentation (if applicable). ### Release Notes RELNOTES: None Closes bazelbuild#29289. PiperOrigin-RevId: 900232825 Change-Id: I7ba3c5282e4f56a6ef803495b03419b9322c8be3
1 parent a7e72ec commit 20886ff

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/main/java/com/google/devtools/build/lib/skyframe/TransitiveBaseTraversalFunction.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,9 @@ public SkyValue compute(SkyKey key, Environment env)
116116
// made to skyframe for building this node was for the corresponding PackageValue.
117117
Iterable<SkyKey> labelAspectKeys =
118118
getStrictLabelAspectDepKeys(env, depMap, targetAndErrorIfAny);
119+
if (env.valuesMissing()) {
120+
return null;
121+
}
119122
SkyframeLookupResult labelAspectEntries = env.getValuesAndExceptions(labelAspectKeys);
120123
if (env.valuesMissing()) {
121124
return null;

0 commit comments

Comments
 (0)