Log when there is a children mismatch, but there aren't actually any missing children.
@@ -249,6 +249,21 @@ public class SimpleCycleDetector implements CycleDetector {
if (childrenNodes.size() != temporaryDirectDeps.numElements()) {
ImmutableSet<SkyKey> childrenSet = ImmutableSet.copyOf(children);
Set<SkyKey> missingChildren = Sets.difference(childrenSet, childrenNodes.keySet());
+ if (missingChildren.isEmpty()) {
+ logger.warning(
+ "Mismatch for children?? "
+ + childrenNodes.size()
+ + ", "
+ + temporaryDirectDeps.numElements()
+ + ", "
+ + childrenSet
+ + ", "
+ + childrenNodes
+ + ", "
+ + key
+ + ", "
+ + entry);
+ } else {
evaluatorContext
.getGraphInconsistencyReceiver()
.noteInconsistencyAndMaybeThrow(
@@ -257,6 +272,7 @@ public class SimpleCycleDetector implements CycleDetector {
GraphInconsistencyReceiver.Inconsistency.ALREADY_DECLARED_CHILD_MISSING);
entry.removeUnfinishedDeps(missingChildren);
}
+ }
children = Maps.filterValues(childrenNodes, nodeEntry -> !nodeEntry.isDone()).keySet();
// This marker flag will tell us when all this node's children have been processed.
