Python – ImportError: No module named PIL

easy-installpythonpython-imaging-library

I use this command in the shell to install PIL:

easy_install PIL

then I run python and type this: import PIL. But I get this error:

Traceback (most recent call last):
  File "<console>", line 1, in <module>
ImportError: No module named PIL

I've never had such problem, what do you think?

Best Answer

In shell, run:

pip install Pillow

Attention: PIL is deprecated, and pillow is the successor.