Closed nightblade9 closed 6 years ago
ImportError: DLL load failed: The specified module could not be found.
This error usually means that the SDL2.dll file bundled with tdl wasn't found (should be at site-packages\tcod\x86\SDL2.dll
on your install.)
I wasn't able to reproduce your issue even while replicating your exact environment (fresh install of Python3.6.4-32 for all users, installing tdl via elevated pip prompt.)
There seems to be something strange about that particular machine. I can't reproduce it on other Windows VMs.
I'll close this for now and re-open it if it reoccurs on another machine. Sorry about that.
I checked that the file is there (it is). I tried granting All Users full access, but the same error repeated. I uninstalled and reinstalled it (granting full access to all users to the Python root installation directory), but I get the same error.
If you have any other ideas, I would like to hear them. I fear this is something generic to my Python installation on Windows 10, rather than a TDL issue (sorry). To be sure, I tried importing the other packages (numpy
, pip
, setuptools
, cffi
, and pycparser
) and I can import them just fine.
I'm going to try uninstalling and installing the 64-bit version of Python instead.
Reinstalling the 64-bit version of Python, with the same caveats, resulted in the same behaviour.
Any ideas?
I just tested tdl on a real Windows 10 computer and it loaded without issues.
Dependency Walker might give you more specific information on what modules are missing if you run it on tcod\_libtcod.pyd
@HexDecimal maybe you can help me validate my installation; how did you install Python, and how did you install TDL?
C:\Program Files
or (x86)
python -m pip install tdl
from a non-admin/sudo/elevated prompt to install TDLLooks like a lot of API-MS-WIN-*
transitive dependencies are missing. Here's a very small subset sample from one dependency in Dependency Walker.
I guess you might need the Visual C++ Redistributables, I thought they were included in Python, but I must have been wrong.
I installed the 2017 64-bit distributable from here (found via Google) and it works now.
Thanks so much for your help with this!
I installed TDL on Windows 10 by running
pip install tdl
from an elevated (administrator) command-prompt. This is necessary because I installed for all users, and presumably my current user doesn't have access to changeC:\ProgramFiles\WhereverPythonLives
.After that, when I execute
import tdl
from Python 3.6.4, I get this error:Any idea what I'm doing wrong? I have a fresh install of Python 3.6.4, I didn't install anything other than TDL yet.