A bunch of unrelated cleanups:
-Have SkylarkImportLookupFunction include causes in the SkyFunctionExceptions it throws.
-Better transitive skyframe error declarations in ASTFileLookupFunction.
-Have ErrorInfo differentiate between direct and transitive transience.
-Introduce ErrorInfoManager and have ParallelEvaluator/ParallelEvaluatorContext use it.

RELNOTES: None
PiperOrigin-RevId: 159163186
diff --git a/src/test/java/com/google/devtools/build/skyframe/ErrorInfoTest.java b/src/test/java/com/google/devtools/build/skyframe/ErrorInfoTest.java
index 6dbeede..a003914 100644
--- a/src/test/java/com/google/devtools/build/skyframe/ErrorInfoTest.java
+++ b/src/test/java/com/google/devtools/build/skyframe/ErrorInfoTest.java
@@ -59,7 +59,9 @@
     assertThat(errorInfo.getException()).isSameAs(exception);
     assertThat(errorInfo.getRootCauseOfException()).isSameAs(causeOfException);
     assertThat(errorInfo.getCycleInfo()).isEmpty();
-    assertThat(errorInfo.isTransient()).isEqualTo(isDirectlyTransient || isTransitivelyTransient);
+    assertThat(errorInfo.isDirectlyTransient()).isEqualTo(isDirectlyTransient);
+    assertThat(errorInfo.isTransitivelyTransient()).isEqualTo(
+        isDirectlyTransient || isTransitivelyTransient);
     assertThat(errorInfo.isCatastrophic()).isFalse();
   }
 
@@ -95,7 +97,7 @@
     assertThat(errorInfo.getRootCauses()).isEmpty();
     assertThat(errorInfo.getException()).isNull();
     assertThat(errorInfo.getRootCauseOfException()).isNull();
-    assertThat(errorInfo.isTransient()).isFalse();
+    assertThat(errorInfo.isTransitivelyTransient()).isFalse();
     assertThat(errorInfo.isCatastrophic()).isFalse();
   }
 
@@ -141,7 +143,7 @@
         new CycleInfo(
             ImmutableList.of(currentKey, Iterables.getOnlyElement(cycle.getPathToCycle())),
             cycle.getCycle()));
-    assertThat(errorInfo.isTransient()).isTrue();
+    assertThat(errorInfo.isTransitivelyTransient()).isTrue();
     assertThat(errorInfo.isCatastrophic()).isTrue();
   }
 
@@ -154,6 +156,7 @@
           /*rootCauseOfException=*/ null,
           ImmutableList.<CycleInfo>of(),
           false,
+          false,
           false);
     } catch (IllegalStateException e) {
       // Brittle, but confirms we failed for the right reason.
@@ -171,6 +174,7 @@
           /*rootCauseOfException=*/ null,
           ImmutableList.<CycleInfo>of(),
           false,
+          false,
           false);
     } catch (IllegalStateException e) {
       // Brittle, but confirms we failed for the right reason.