Skip to content

Commit b40b8bc

Browse files
committed
Export the shell package unconditionally
1 parent ea577a0 commit b40b8bc

File tree

3 files changed

+2
-8
lines changed

3 files changed

+2
-8
lines changed

graalpython/com.oracle.graal.python.shell/src/META-INF/native-image/org.graalvm.python.shell/python-launcher/native-image.properties

Lines changed: 0 additions & 1 deletion
This file was deleted.

graalpython/com.oracle.graal.python.shell/src/com/oracle/graal/python/shell/GraalPythonMain.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333
import java.io.IOException;
3434
import java.io.InputStream;
3535
import java.io.OutputStream;
36-
import java.lang.invoke.MethodHandles;
3736
import java.lang.management.ManagementFactory;
3837
import java.nio.file.Files;
3938
import java.nio.file.InvalidPathException;
@@ -56,7 +55,6 @@
5655
import org.graalvm.polyglot.Context;
5756
import org.graalvm.polyglot.Context.Builder;
5857
import org.graalvm.polyglot.Engine;
59-
import org.graalvm.polyglot.HostAccess;
6058
import org.graalvm.polyglot.PolyglotException;
6159
import org.graalvm.polyglot.Source;
6260
import org.graalvm.polyglot.Value;
@@ -826,11 +824,6 @@ protected void launch(Builder contextBuilder) {
826824
contextBuilder.engine(Engine.newBuilder().allowExperimentalOptions(true).options(enginePolyglotOptions).build());
827825
}
828826

829-
if (GraalPythonMain.class.getModule().isNamed()) {
830-
// Needed so that we can access JLine callback via interop
831-
contextBuilder.extendHostAccess(HostAccess.ALL, builder -> builder.useModuleLookup(MethodHandles.lookup()));
832-
}
833-
834827
int rc = 1;
835828
try (Context context = contextBuilder.build()) {
836829
runVersionAction(versionAction, context.getEngine());

mx.graalpython/suite.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -918,6 +918,8 @@
918918
"name": "org.graalvm.py.launcher",
919919
"exports": [
920920
"com.oracle.graal.python.shell to org.graalvm.launcher",
921+
# Exported to be accessible from readline callbacks
922+
"com.oracle.graal.python.shell",
921923
],
922924
},
923925
"useModulePath": True,

0 commit comments

Comments
 (0)