Closed kurte32 closed 1 year ago
This definitely looks less like bug and more like an environment issue.
If you open up a python shell in one of these virtual environments and execute import eel
- do you get the same error?
I am also facing the similar issue of DLL not found for another library. If I open the python shell in a virtual environment and execute the import statement, it works perfectly fine, only after building the .exe and the error shows up
Traceback (most recent call last):
File "PDFNetPython.py", line 14, in swig_import_helper
File "importlib\__init__.py", line 127, in import_module
File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 657, in _load_unlocked
File "<frozen importlib._bootstrap>", line 556, in module_from_spec
File "<frozen importlib._bootstrap_external>", line 1101, in create_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
ImportError: DLL load failed while importing _PDFNetPython: The specified module could not be found.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "gui.py", line 17, in <module>
File "PyInstaller\loader\pyimod03_importers.py", line 495, in exec_module
File "dpf_main.py", line 1, in <module>
File "PyInstaller\loader\pyimod03_importers.py", line 495, in exec_module
File "PDFNetPython3\__init__.py", line 18, in <module>
File "PyInstaller\loader\pyimod03_importers.py", line 495, in exec_module
File "PDFNetPython.py", line 17, in <module>
File "PDFNetPython.py", line 16, in swig_import_helper
File "importlib\__init__.py", line 127, in import_module
ImportError: DLL load failed while importing _PDFNetPython: The specified module could not be found.
@richylyq your issue is in the output executable whereas the problem in this issue is regarding running auto-py-to-exe (missing dll in a dependency).
If you want to report this, you could create a new issue and fill out the template.
@kurte32, I had this same exception happen to me on both a Windows 10 and Windows 11 VM. Are you sure you have the Visual C++ Redistributable Packages installed? This fixed the problem for me.
I downloaded version 14 from here: https://www.microsoft.com/en-ca/download/details.aspx?id=48145
This issue is stale because it has been open for 60 days with no activity. Remove stale label or comment on this issue or it will be closed in 5 days.
@kurte32, I had this same exception happen to me on both a Windows 10 and Windows 11 VM. Are you sure you have the Visual C++ Redistributable Packages installed? This fixed the problem for me.
I downloaded version 14 from here: https://www.microsoft.com/en-ca/download/details.aspx?id=48145
Hi, just came back to say thanks, this worked :)
@kurte32, I had this same exception happen to me on both a Windows 10 and Windows 11 VM. Are you sure you have the Visual C++ Redistributable Packages installed? This fixed the problem for me.
I downloaded version 14 from here: https://www.microsoft.com/en-ca/download/details.aspx?id=48145
You are the GOAT
I have used auto-py-to-exe several time in the past with great results, however been having this issue for the last couple of days and I have not been able to fix it/found a fix I have tried the 3 methods of installation (PyPI, Install GitHub, and Running Locally) both in a VirtualEnv and Global, however I keep getting the same error.
I have also changed my Python version, started with 3.11 and went all the way to 3.8.10, updated my OS, but ran out of luck