File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed
graalpython/com.oracle.graal.python.shell/src/com/oracle/graal/python/shell Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -58,6 +58,7 @@ public static void main(String[] args) {
58
58
}
59
59
60
60
private static final String LANGUAGE_ID = "python" ;
61
+ private static final String MIME_TYPE = "text/x-python" ;
61
62
62
63
private ArrayList <String > programArgs = null ;
63
64
private String commandString = null ;
@@ -306,7 +307,7 @@ private void evalNonInteractive(Context context) throws IOException {
306
307
src = Source .newBuilder (getLanguageId (), commandString , "<string>" ).build ();
307
308
} else {
308
309
assert inputFile != null ;
309
- src = Source .newBuilder (getLanguageId (), new File (inputFile )).build ();
310
+ src = Source .newBuilder (getLanguageId (), new File (inputFile )).mimeType ( MIME_TYPE ). build ();
310
311
}
311
312
context .eval (src );
312
313
}
You can’t perform that action at this time.
0 commit comments