Change checkRuntime to take a CommandEnvironment instead. I wanted to merge it into beforeCommand, but the reporter isn't set up yet when we call beforeCommand. Hopefully we can refactor the code to merge it in the future. -- MOS_MIGRATED_REVID=103179268
diff --git a/src/main/java/com/google/devtools/build/lib/runtime/BlazeCommandDispatcher.java b/src/main/java/com/google/devtools/build/lib/runtime/BlazeCommandDispatcher.java index cb0a0f9..b43e0cea 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/BlazeCommandDispatcher.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/BlazeCommandDispatcher.java
@@ -361,7 +361,7 @@ System.setErr(new PrintStream(reporterOutErr.getErrorStream(), /*autoflush=*/true)); for (BlazeModule module : runtime.getBlazeModules()) { - module.checkRuntime(runtime); + module.checkEnvironment(env); } if (commonOptions.announceRcOptions) {
diff --git a/src/main/java/com/google/devtools/build/lib/runtime/BlazeModule.java b/src/main/java/com/google/devtools/build/lib/runtime/BlazeModule.java index 68eed55..97d9b21 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/BlazeModule.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/BlazeModule.java
@@ -360,9 +360,9 @@ } /** - * Perform module specific check of current blaze runtime. + * Perform module specific check of current command environment. */ - public void checkRuntime(BlazeRuntime runtime) { + public void checkEnvironment(CommandEnvironment env) { } /**