how to find out vesion of a python module

Gary Herron gherron at islandtraining.com
Mon Feb 9 20:07:10 EST 2009


Atishay wrote:
> I have Python Image Library installed. I do not know how to find out
> its version. How can I do that?
>   

There is no standard way.  However many module authors do include soch
information, usually in an attribute named version or __version__, or
VERSION.  PIL uses the VERSION

import Image
print Image.VERSION

> Secondly, I get error if I say "import ImageFont"
>
> ImportError: The _imaging C module is not installed
>
> I have _imaging module though
>
> [bash]# file PIL/_imaging.so
>
> PIL/_imaging.so: ELF 32-bit LSB shared object, Intel 80386, version 1
> (SYSV), not stripped
>
> How could I fix this?
>   

It looks like you have it installed incorrectly,   How did you install
it.  What platform/system are you on? 
PIL usually uses a PIL.pth file.  Does that exist?  Where? And what are
its contents?

Gary Herron


> --
> http://mail.python.org/mailman/listinfo/python-list
>   




More information about the Python-list mailing list