|
|
@@ -27,6 +27,11 @@ public class PythonParse implements ScriptParse {
|
|
|
|
|
|
static {
|
|
|
//初始化python环境
|
|
|
+
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ public PythonParse() {
|
|
|
PySystemState systemState = Py.getSystemState();
|
|
|
Properties props = new Properties();
|
|
|
props.setProperty("python.console.encoding", "UTF-8");
|
|
|
@@ -38,10 +43,6 @@ public class PythonParse implements ScriptParse {
|
|
|
PythonInterpreter.initialize(preprops, props, new String[0]);
|
|
|
PythonInterpreter.initialize(System.getProperties(), props, new String[] {});
|
|
|
log.info("python path >>>>>>>>>>>>>>>>>:{}",systemState.path);
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
- public PythonParse() {
|
|
|
interpreter = new PythonInterpreter();
|
|
|
|
|
|
}
|