Tuesday, 4 June 2013

Python - PIL Import Error on Windows

# For Invidual case, Windows 7 x64, Python 2.7, PIL 1.1.7 Windows Binary

CMD (Virtual Env)
easy_install PIL-1.1.7.win32-py2.7.exe
Python Shell
from PIL import Image
change to
import Image
Try & Catch
try:
  from PIL import Image
except ImportError:
  try:
    import Image
OR

Change Directory Name
\Lib\site-packages\PIL-1.1.7-py2.7-win32.egg
to
\Lib\site-packages\PIL

Referencehttps://code.djangoproject.com/ticket/6054

No comments :

Post a Comment