How to import *.pyc file from different version of python?
Posted
by Almog
on Stack Overflow
See other posts from Stack Overflow
or by Almog
Published on 2010-04-24T16:50:30Z
Indexed on
2010/04/24
16:53 UTC
Read the original article
Hit count: 301
Hello, I used python 2.5 and imported a file named "irit.py" from C:\util\Python25\Lib\site-packages directory. This files imports the file "_irit.pyc which is in the same directory. It worked well and did what I wanted. Than, I tried the same thing with python version 2.6.4. "irit.py" which is in C:\util\Python26\Lib\site-packages was imported, but "_irit.pyc" (which is in the same directory of 26, like before) hasn't been found. I got the error message:
File "C:\util\Python26\lib\site-packages\irit.py", line 5, in import _irit ImportError: DLL load failed: The specified module could not be found.
Can someone help me understand the problem and how to fix it?? Thanks, Almog.
© Stack Overflow or respective owner