[Cython] ImportError with cimport within package

Stefan Behnel stefan_ml at behnel.de
Fri Feb 27 09:50:09 CET 2009


Mikael Arvids wrote:
> Robert Bradshaw writes:
> 
>> Are module_A.pyx, module_A.pxd, module_B.pyx, module_B.pxd inside the  
>> package directory as well?
> 
> I had the Cython files in a separate directory earlier, but I tried with
> everything in the same folder, recompiled, and still the same problem.

What Robert mean, was: Did you compile the module from source files that
are inside the package directory? Cython needs to know the package
structure at compile time, it's not enough to move the shared libraries around.

Stefan



More information about the Cython-dev mailing list