[wingide-users] Wing cant import the amara module while ipython can

Wingware Support support at wingware.com
Fri Nov 14 08:04:03 MST 2008

Michael Bernhard Arp Sørensen wrote:
> That did not help me or pylint. :-) But I found a workaround.
> I opened the egg, which is a zip file, and copyed the folder named 
> "amara" into the base directory of my source code. After that, pylint 
> imports amara easely.

Another way _may_ be to unzip the egg in place and add the directory
/usr/lib/python2.5/site-packages/Amara- (now the
unzipped egg) to your Python Path.

Obviously, you may not need to do this, but I mention it in case it
turns out to be useful in other cases.

> Apparantly, a folder with code is regarded as a module IF there's a file 
> in that folder called __init__.py. I believe I've heard that before 
> somewhere else.

Yes, the file __init__.py makes the folder into a package so you can
'import <name of folder>' in the same way as you 'import <name of file>'
for modules.


Stephan Deibel
Wingware | Python IDE
Advancing Software Development


More information about the wingide-users mailing list