|
@@ -238,10 +238,8 @@ public class PythonTask extends AbstractTaskExecutor {
|
|
|
private String buildPythonExecuteCommand(String pythonFile) {
|
|
|
Preconditions.checkNotNull(pythonFile, "Python file cannot be null");
|
|
|
|
|
|
- String pythonHome = System.getenv(PYTHON_HOME);
|
|
|
- if (StringUtils.isEmpty(pythonHome)) {
|
|
|
- return DEFAULT_PYTHON_VERSION + " " + pythonFile;
|
|
|
- }
|
|
|
+ String pythonHome = String.format("${%s}", PYTHON_HOME);
|
|
|
+
|
|
|
return pythonHome + " " + pythonFile;
|
|
|
}
|
|
|
|