1

当我尝试访问产品或目录时出现此错误

我已经安装了 libjpeg-dev,然后是 pil。

我在本地运行 django_oscar 沙箱。我应该怎么办 ?

还请指定我应该添加哪些附加信息??

IOError at /catalogue/

decoder jpeg not available

Request Method:     GET
Request URL:    http://127.0.0.1:8888/catalogue/
Django Version:     1.4.6
Exception Type:     IOError
Exception Value:    

decoder jpeg not available

Exception Location:     /home/vagrant/oscar/local/lib/python2.7/site-packages/PIL/Image.py in _getdecoder, line 385
Python Executable:  /home/vagrant/oscar/bin/python
Python Version:     2.7.3
Python Path:    

['/vagrant/projects/ecommerce/clone/django-oscar/sites/sandbox',
 '/home/vagrant/oscar/local/lib/python2.7/site-packages/distribute-0.6.24-py2.7.egg',
 '/home/vagrant/oscar/local/lib/python2.7/site-packages/pip-1.1-py2.7.egg',
 '/vagrant/projects/ecommerce/clone/django-oscar',
 '/home/vagrant/oscar/local/lib/python2.7/site-packages/django_treebeard-2.0b1-py2.7.egg',
 '/home/vagrant/oscar/lib/python2.7',
 '/home/vagrant/oscar/lib/python2.7/plat-linux2',
 '/home/vagrant/oscar/lib/python2.7/lib-tk',
 '/home/vagrant/oscar/lib/python2.7/lib-old',
 '/home/vagrant/oscar/lib/python2.7/lib-dynload',
 '/usr/lib/python2.7',
 '/usr/lib/python2.7/plat-linux2',
 '/usr/lib/python2.7/lib-tk',
 '/home/vagrant/oscar/local/lib/python2.7/site-packages',
 '/home/vagrant/oscar/local/lib/python2.7/site-packages/PIL']
4

1 回答 1

1

如果你使用的是 ubuntu,奥斯卡作者有一篇关于这个的可爱博客文章 :)

http://codeinthehole.com/writing/how-to-install-pil-on-64-bit-ubuntu-1204/

于 2013-12-18T16:07:41.437 回答