I am trying to install PIL module But I end up with an error :

0 votes
$ pip install PIL
ERROR: Could not find a version that satisfies the requirement PIL (from versions: none)
ERROR: No matching distribution found for PIL

Can Anyone suggest me any other way to install it.

Thanking You...!!!

Apr 6 in Python by Nishant
• 210 points
415 views

Hey, @Nishant,

Try installing the package named Pillow, it's a PIL Fork. You can use it the same as the PIL package.

Hi Gitika,

I have already installed the pillow package, but my program is still showing me the error for PIL module.

I am trying to run a program which is using MyQR package and it is showing me the following error :

$ C:/Python/Python38/python.exe d:/MCA/MyProject/Project/generate.py
Traceback (most recent call last):
  File "d:/MCA/MyProject/Project/generate.py", line 1, in <module>
    from MyQR import myqr
  File "C:\Python\Python38\lib\site-packages\MyQR\myqr.py", line 5, in <module>
    from MyQR.mylibs import theqrmodule
  File "C:\Python\Python38\lib\site-packages\MyQR\mylibs\theqrmodule.py", line 3, in <module>
    from MyQR.mylibs import data, ECC, structure, matrix, draw
  File "C:\Python\Python38\lib\site-packages\MyQR\mylibs\draw.py", line 3, in <module>
    from PIL import Image
ModuleNotFoundError: No module named 'PIL'

Please help me in this

Thanking You...!!!


1 answer to this question.

+1 vote

Hi@Nishant,

You can use PILLOW instead of PIL.

$ pip3 install PILLOW
Collecting PILLOW
  Downloading https://files.pythonhosted.org/packages/ba/90/8a24e6220cfcf6a3a0162535d5b926e774117e384ff921908e07e4c92bda/Pillow-7.1.1-cp36-cp36m-manylinux1_x86_64.whl (2.1MB)
    100% |████████████████████████████████| 2.1MB 281kB/s
Installing collected packages: PILLOW
Successfully installed PILLOW-7.1.1

[root@vm1 ~]# python3
Python 3.6.6 (default, Mar 29 2019, 00:03:27)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-36)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import PIL
>>>

Now it works fine. Try this once.

answered Apr 6 by MD
• 22,520 points
Thank you so much for the help.

Now It's working properly.

Related Questions In Python

0 votes
0 answers

I am trying to install PyBase64 on my python 3.8. But I end up with the following error:

$ pip install pybase ERROR: Could not find ...READ MORE

Mar 24 in Python by Nishant
• 210 points
188 views
0 votes
0 answers

I am trying to install os-win on my python 3.8. But I end up with the following error:

ERROR: Command errored out with exit status ...READ MORE

Mar 24 in Python by Nishant
• 210 points
280 views
0 votes
0 answers

I am trying to install pyknow but i get this error

could not find a version that  satisfies ...READ MORE

Mar 4 in Python by Maria
• 120 points
280 views
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 6, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 939 views
0 votes
0 answers
0 votes
1 answer

I am trying to install visualize on my python 3.8 but i end up with the followinf error.

Hi@Avinash, I think the module name is visualization ...READ MORE

answered Apr 27 in Python by MD
• 22,520 points
46 views
0 votes
2 answers

i am installing wordcloud using pip but i am unable to do that ....i am getting the following error

Hi@Prajwala, First check your pip and python version ...READ MORE

answered Apr 15 in Python by MD
• 22,520 points
736 views