0

I am trying to use the library optapy with a conda environment created locally. I have installed all of the libraries I needes to, also installed Java JDK-17.0.6.10 and created a JAVA-HOME variable. But when I try to run and try to use optapy it doesn't let me and all I get is a big error where it says the OSError: could not get source code.

pd: I'm using python 3.9

error message error message 2

I hope someone can help me with this problem and tell me what to do

vctrgv
  • 1
  • What the exception above "During the handling of the above exception, another exception occur"? The traceback in the image does not point to any optapy code (and seems to be related to prettifying the actual traceback). Can you give the full traceback please? – Christopher Chianelli Mar 06 '23 at 19:31

1 Answers1

0

From the top error message, it appears Java 8 is being used; OptaPlanner and OptaPy require Java 11. The environment variable that need to be set is JAVA_HOME, not JAVA-HOME; ensure JAVA_HOME is set to the path where Java JDK-17.0.6.10 is installed.

Christopher Chianelli
  • 1,163
  • 1
  • 8
  • 8