jpype-project / jpype

JPype is cross language bridge to allow Python programs full access to Java class libraries.
http://www.jpype.org
Apache License 2.0
1.12k stars 183 forks source link

ImportError: DLL load failed while importing _jpype: The specified module could not be found. #1189

Closed muhammedrinshid closed 6 months ago

muhammedrinshid commented 6 months ago

Hi everyone,

I'm encountering an issue when trying to use the optapy library in my Python project. Specifically, I'm getting an ImportError related to JPype when I attempt to import optapy. Here are the details of the error:

*File "", line 1, in File "C:\Users\admin\Desktop\optapyTest\optapy-env\lib\site-packages\optapy__init__.py", line 11, in from .annotations import File "C:\Users\admin\Desktop\optapyTest\optapy-env\lib\site-packages\optapy\annotations.py", line 1, in import jpype File "C:\Users\admin\Desktop\optapyTest\optapy-env\lib\site-packages\jpype__init__.py", line 18, in import _jpypeImportError: DLL load failed while importing _jpype: The specified module could not be found.**

Operating System: (e.g., Windows 11) Python Version: ( Python 3.9.10) Java Version: (openjdk 21.0.3 2024-04-)

Thrameos commented 6 months ago

Your install of JPype is incomplete. Likely it was copied in such a way that it does not include the C++ based support module. Uninstall JPype and reinstall it again so that it can hopefully install the missing piece.

ryanmkurtz commented 4 months ago

I reported a similar error in a ticket that is still open.