Django deployment: PIL and virtualenv problem
Posted
by AndriJan
on Stack Overflow
See other posts from Stack Overflow
or by AndriJan
Published on 2010-03-08T22:18:23Z
Indexed on
2010/03/08
22:21 UTC
Read the original article
Hit count: 727
Hey guys,
I'm deploying a Django site on my Vserver (Debian Lenny) and I'm having problem with PIL.
I'm using virtualenv as well. When I'm in the virtualenv and type pip install -U PIL everything installs fine and I get this:
*** TKINTER support not available
--- JPEG support available
--- ZLIB (PNG/ZIP) support available
*** FREETYPE2 support not available
*** LITTLECMS support not available
And when I go in to the shell (python manage.py shell) and type
from PIL import Image
I get no error.
But when I use it in the Django project (uploading an image in the admin for example) I just get
No module named PIL
I don't think it's a problem with the model because it works fine on the development machine but here is part of the class:
class Category(models.Model):
name = models.CharField(max_length=255, verbose_name="Name")
logo = models.ImageField(upload_to='images/category/', blank=True, null=True, verbose_name="Logo")
I'm going out of my mind about this. I feel like this is a very common issue but I've been trying to google this all day with no luck.
Thanks in advance, AndriJan
© Stack Overflow or respective owner