From 4dca905533c30badfaf25388a5fa226ed276edb8 Mon Sep 17 00:00:00 2001 From: Chenchu Kolli Date: Mon, 9 May 2022 19:42:58 -0500 Subject: [PATCH] Improve error message for unresolved toolchains (#15451) Closes #15135. PiperOrigin-RevId: 447028054 Co-authored-by: Christopher Peterson Sauer --- .../skyframe/ToolchainResolutionFunction.java | 21 +- .../ToolchainResolutionFunctionTest.java | 190 ++++++++++++++++++ src/test/shell/bazel/toolchain_test.sh | 16 +- 3 files changed, 205 insertions(+), 22 deletions(-) diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/ToolchainResolutionFunction.java b/src/main/java/com/google/devtools/build/lib/skyframe/ToolchainResolutionFunction.java index f579293b6f484a..2122cad3af7fe9 100644 --- a/src/main/java/com/google/devtools/build/lib/skyframe/ToolchainResolutionFunction.java +++ b/src/main/java/com/google/devtools/build/lib/skyframe/ToolchainResolutionFunction.java @@ -24,7 +24,6 @@ import com.google.common.collect.ImmutableMap; import com.google.common.collect.ImmutableSet; import com.google.common.collect.ImmutableSetMultimap; -import com.google.common.collect.Iterables; import com.google.common.collect.Table; import com.google.devtools.build.lib.analysis.PlatformConfiguration; import com.google.devtools.build.lib.analysis.config.BuildConfiguration; @@ -578,20 +577,14 @@ protected Code getDetailedCode() { } private static String getMessage(List