问题
IllegalStateException: No language and polyglot implementation was found on the classpath. Make sure the truffle-api.jar is on the classpath.
I wanted to use GraalVM in my Java project.
I added this dependency to my pom.xml
<dependency>
<groupId>org.graalvm.js</groupId>
<artifactId>js-scriptengine</artifactId>
<version>1.0.0-rc10</version>
</dependency>
but apparently that's not enough.
What else do I have to do to fix this error?
回答1:
Had to add all these dependencies:
<dependency>
<groupId>org.graalvm.js</groupId>
<artifactId>js</artifactId>
<version>1.0.0-rc10</version>
</dependency>
<dependency>
<groupId>org.graalvm.js</groupId>
<artifactId>js-scriptengine</artifactId>
<version>1.0.0-rc10</version>
</dependency>
<dependency>
<groupId>org.graalvm.truffle</groupId>
<artifactId>truffle-api</artifactId>
<version>1.0.0-rc10</version>
</dependency>
来源:https://stackoverflow.com/questions/54384499/illegalstateexception-no-language-and-polyglot-implementation-was-found-on-the