Error when launching JVM with jpype wrapper

Dear all,

I’m failing to run the Jpype wrapper on a Windows machine.
I have a .venv on Pycharm with orekit-jpype installed
When I run the following script:

import orekit_jpype as orekit
orekit.initVM()

if __name__ == '__main__':
    pass

I get the following error:

Error occurred during initialization of VM
Could not find agent library instrument on the library path, with error: La proc�dure sp�cifi�e est introuvable
Module java.instrument may be missing from runtime image.

Process finished with exit code 1

I’ve got Java 21 on my machine and if I do jpype.getDefaultJVMPath() it’s giving its location.

Cheers,
Romain.

FYI it runs fine with jpype 1.5.0, so the problem comes from 1.5.1 (latest)

This issue seems to be known by the jpype devs: Failure to start JVM with jpype 1.5.1 on Windows · Issue #1242 · jpype-project/jpype · GitHub

Let’s hope a new jpype version with a fix will be published soon, in the meantime you’ll have to stick to jpype 1.5.0.

I created a gitlab issue as well as a merge request which freezes jpype==1.5.0 in the orekit jpype dependencies.

1 Like

A new version of orekit-jpype, 12.2.1.1, was pushed to PyPi (thanks Petrus!). It now depends on jpype version 1.5.0 while waiting for a new jpype release containing the fix.