On Jun 12, 6:27 am, Kenneth <kenneth.t.lundst...@gmail.com> wrote:
> Thank you Richard for the fast reply,
>
> I tested with python and "from PIL import Image" and the only result
> was a new line, so I´m guess python finds PIL but not web2py.

Kenneth -

This means your two Python environments are different.   If you
installed PIL in your python instance as a user (for example) then
your web2py might not see that installation.

A comparison of sys.path in the two environment can help you see
this.   Try showing  sys.path in a sample page, and compare to what
you get for sys.path from your command line.

- Yarko

>
> Kenneth
>
> On Jun 12, 1:59 pm, Richard <richar...@gmail.com> wrote:
>
>
>
> > you likely installed PIL from source into a directory not in your
> > Python path.
>
> > From the command line you can use PIL with:
> > $ python
>
> > >>> from PIL import Image
>
> > On Jun 12, 8:50 pm, Kenneth <kenneth.t.lundst...@gmail.com> wrote:
>
> > > Hello,
>
> > > I´m trying to create thumbnails from images uploaded to my
> > > application. I´ve found a couple of ways to do this but I need PIL to
> > > get things to work. I installed PIL from source and some extra
> > > libraries (jpeg, freetype).
>
> > > But I still get error "No module named PIL".
>
> > > I´m 99% sure this is not a web2py issue but maybe somebody can help me
> > > out.
>
> > > I´m running on an CentOS 5.x server, Apache and mod_wsgi. As I have
> > > understod you don´t have to "install" PIL into web2py.
>
> > > How do I test from command line that python finds PIL?
>
> > > Kenneth

Reply via email to