No module named urllib3

0 votes
The following is a script to call an API. But I am getting the following error message while running it:

Traceback (most recent call last):
  File "user_audit.py", line 2, in <module>
    import requests
  File "c:\Python27\lib\site-packages\requests\__init__.py", line 60, in <module>
    from .packages.urllib3.exceptions import DependencyWarning
  File "c:\Python27\lib\site-packages\requests\packages\__init__.py", line 29, in <module>
    import urllib3
ImportError: No module named urllib3
 

I've confirmed that packages is up to date, tried uninstalling and reinstalling it, but nothing has worked so far. Can someone help?
Jan 24 in Python by ana1504.k
• 5,870 points
446 views

1 answer to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

It is possible that either urllib3 is not imported or not installed.

Now, to import ,write import urllib3 at the top of the file to install write pip install urllib3 into terminal. you may not activate environment variable correctly. to activate environment variable , write source env/bin/activate into terminal. here env is environment variable name.

Hope this helps!

answered Jan 24 by SDeb
• 9,300 points

Related Questions In Python

0 votes
1 answer

ImportError: No module named requests

Requests is not available for use by ...READ MORE

answered Jun 26, 2018 in Python by Hamartia's Mask
• 1,580 points
475 views
+3 votes
1 answer

Tensorflow 1.5 ImportError: No module named tensorflow.python.client

I think it's a bug in Tensorflow ...READ MORE

answered Sep 25, 2018 in Python by charlie_brown
• 7,710 points
1,422 views
0 votes
1 answer

tensorflow 1.5 ImportError: No module named tensorflow.python.client

Some of the modules have changed in ...READ MORE

answered Oct 5, 2018 in Python by Priyaj
• 56,100 points
189 views
0 votes
1 answer

tensorflow 1.5 ImportError: No module named tensorflow.python.client

Some of the modules have changed in ...READ MORE

answered Oct 9, 2018 in Python by Priyaj
• 56,100 points
77 views
0 votes
1 answer

how can i count the items in a list?

suppose you have a list a = [0,1,2,3,4,5,6,7,8,9,10] now ...READ MORE

answered May 2 in Python by Mohammad
• 920 points
18 views
0 votes
1 answer

No module named __future__

In your /PATH/Python-2.7.x/Lib should be all your ...READ MORE

answered Mar 7 in Python by SDeb
• 9,300 points
13 views
0 votes
1 answer

Difference between module and Package in Python

A module is basically a single file ...READ MORE

answered Nov 13, 2018 in Python by SDeb
• 9,300 points
66 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.