ImportError in embedded Python Interpreter

googler.1.webmaster at spamgourmet.com googler.1.webmaster at spamgourmet.com
Thu Jan 29 14:04:39 EST 2009


Hi,

i have a problem. I compiled Python and the socket module so I got
this structure. (all on windows)

C:\test\dll_files\python25.dll
C:\test\my_app
C:\test\dll_files\DLLs\
C:\test\dll_files\python.exe

If I run python I get the console and I can call "import socket" which
succeeds. I wrote a small console app which is stored in C:\test\ and
embeddeds the python interpreter. I set the environment variable PATH
so the python DLL files can be load.

But when I want to import in a script the socket module, it fails.
(The interpreter works fine, just importing files in the DLLs folder
fail). Why? When I print out the sys.path I get the same like in the
real python.exe.

What do you think, whats missing?


Thanks a lot. bye :)



More information about the Python-list mailing list