From 0145f79d70ee7fea9c3bea5291bf8b8e2fa90533 Mon Sep 17 00:00:00 2001 From: dmarting Date: Mon, 4 Sep 2017 15:30:57 +0200 Subject: Throws an ISE when a handler is not defined The only case this exception is thrown is when there is a bug in Bazel and we should surface the whole stacktrace. See #3664 PiperOrigin-RevId: 167492638 --- .../build/lib/rules/repository/RepositoryDelegatorFunction.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/main/java/com/google/devtools') diff --git a/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java b/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java index c64c44c647..a14800870d 100644 --- a/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java +++ b/src/main/java/com/google/devtools/build/lib/rules/repository/RepositoryDelegatorFunction.java @@ -129,9 +129,8 @@ public final class RepositoryDelegatorFunction implements SkyFunction { handler = handlers.get(rule.getRuleClass()); } if (handler == null) { - throw new RepositoryFunctionException( - new EvalException(rule.getLocation(), "Could not find handler for " + rule), - Transience.PERSISTENT); + throw new IllegalStateException( + new EvalException(rule.getLocation(), "Could not find handler for " + rule)); } handler.setClientEnvironment(clientEnvironment); -- cgit v1.2.3