Does anyone know how to install Polyglot languages (e.g. org.graalvm.polyglot/python) with deps.edn https://medium.com/graalvm/truffle-unchained-13887b77b62c? I have installed graalvm-jdk-21 with jenv and the following deps:
org.graalvm.truffle/truffle-api {:mvn/version "23.1.1"}
org.graalvm.polyglot/polyglot {:mvn/version "23.1.1"}
I would also like to add the following, but these are not jar-based dependencies so are not found by the clojure installer.
org.graalvm.polyglot/python {:mvn/version "23.1.1"}
org.graalvm.polyglot/js {:mvn/version "23.1.1"}
However if I generate a pom.xml from my deps.edn file and add the following pom deps https://www.graalvm.org/latest/reference-manual/embed-languages/#dependency-setup...
org.graalvm.polyglot
python
23.1.1
pom
org.graalvm.polyglot
js
23.1.1
pom
I can get these installed in ~/.m2:
$ ls /Users/m/.m2/repository/org/graalvm/python/python-language/23.1.1/
total 164096
-rw-r--r--@ 1 m staff 212 Dec 30 12:25 _remote.repositories
-rw-r--r--@ 1 m staff 82454961 Dec 30 12:25 python-language-23.1.1.jar
-rw-r--r--@ 1 m staff 40 Dec 30 12:25 python-language-23.1.1.jar.sha1
-rw-r--r--@ 1 m staff 3305 Dec 30 12:24 python-language-23.1.1.pom
-rw-r--r--@ 1 m staff 40 Dec 30 12:24 python-language-23.1.1.pom.sha1
Now I could add these jar files as :local/root dependencies, but their dependencies described in the pom file are not loaded.
Has anyone else solved this? @wombawomba you recently had a similar problem, although it seems you were using lein. Did you manage to get it working?I think there was an issue with jar vs pom dependencies (whatever they may be)
I have no clue what they are but people in #tools-deps know
OK thanks for the reference! will ask there
I downgraded instead of solving it :) The problem I had seems to be with module files getting overwritten in uberjars, so the solution would probably be to avoid using uberjars
I managed to get it working by adding all the deps from e.g. python-language-23.1.1.pom to my deps.edn, but I also had to pass extra flags to the Python context about where the stdlib is etc. So overall the solution was not that nice, so I downgraded as well.