Jpype wrapper with Orekit snapshot

Hi guys,

I was wondering how difficult it would be to locally build a version of the jpype wrapper with Orekit snapshot or a modified version of the library.

Cheers,
Romain.

Hi Serrof,

Very easy, that is one of the advantages of the jpype wrapper that there is no compilation involved with the jar.

I did an example of how to add custom java jar (additional features) in GitHub - petrushy/jpype_java_extension_example

For a snapshot version you can also just replace the orekit jar in the jars directory of the python (installed) folder and remove the old one.

Regards

3 Likes

Dear Petrus,

further question:
if a class only exists in the snapshot and not the official release, would the wrapping work for it if I replace the .jar in the lib?

Cheers,
Romain.

@Serrof ,

I may not understand the question fully, but if you replace the orekit-X.X.jar with the orekit-SNAPSHOT-X.Y.jar in the python package, the classes in the SNAPSHOT will be available in the wrapper.

1 Like

That’s awesome. In the end I found it simpler for my user case to have a java project depending on Orekit, compile it and add the jar to the wrapper like in the example on the official repo.
I guess the only drawback is the absence of stubs.

Anyway, thanks a lot @petrus.hyvonen and @yzokras for maintaining the Jpype wrapper it’s a great tool.

Cheers,
Romain.

3 Likes

Great to hear! If there is a user need for Python snapshot releases, we could consider setting up a CI pipeline publishing Python wheels to the Gitlab’s PyPi package registry whenever a new Orekit Java snapshot is released.