AccessInit: hash collision: 3 for both 1 and 1
When I run "manage.py sql", I get this:
AccessInit: hash collision: 3 for both 1 and 1
exit code 1
On several manage.py commands.
I read about it at http://stackoverflow.com/questions/6708409/sphinx-error-accessinit-hash-collision-3-for-both-1-and-1
but setting PYTHONPATH gives me problems using pycharm.
I did install PIL in a virtualenv using the trick from:
http://nedbatchelder.com/blog/201007/installing_python_packages_from_windows_installers_into.html
PIL is not in my global env.
How to avoid/investigate this error?
请先登录再写评论。
Hi Kurdy,
do you run Tools->Run manage.py task from pycharm?
Can you run command successfully from the command line?
There are a lot of modules that uses PIL different from Django (SciPy, Pigments, Sphinx etc.) For many
of them it helps to install the latest distributed version.
Also known solution is to add
Hi Catherine,
Yes, I did run Tools->Run manage.py task from pycharm
And yes, I can use the command successfully from the command line.
I did use the latest available PIL: PIL-1.1.7.win32-py2.7.exe
Since I have a django-cms project configured in PyCharm, I do not maintain any of the core code.
That is, I don't know where I would have to add this hack.
Hi Catherine,
Any news on this one?
I just registered an account to say the following has work for me:
import PIL.Image as Image
that's it.
Step to reproduce:
Create new django project
Install django-filer
Install easy-thumbnails
All in new virtualenv.
Try run manage.py syncdb (Ctrl + Alt + R)
I'm not completely sure on my environment, since I first tried install of PIL as in my initial post, and than removed it and reinstalled it globally.
The issue seems to be the way those apps import the PIL module:
easy-thumbnails / easy_thumbnails / engine.py
from PIL import Image
django-filer / filer / thumbnail_processors.py
from PIL import Image
You can replace those lines yourself, not sure if that's the only place where PIL is imported (you can run a search in pycharm).
You should do:
import PIL.Image as Image
This is a bug in pycharm of course, and I dont think they are going to fix it any time soon.
What exactly is a bug in PyCharm, and how do you envision us fixing it? The original post describing the issue does not mention PyCharm at all:
http://jaredforsyth.com/blog/2010/apr/28/accessinit-hash-collision-3-both-1-and-1/