Module is not found after import and download - python

I just switched my code from Replit to Visual Code Studio and I have pip, python, and discord.py installed. I also installed requests by doing pip install requests and it downloaded it fine. Whenever i run the code, i get this error. How can i fix this issue?
File "c:\Users\colee\Desktop\Ultimate Bot\main.py", line 5, in <module>
import requests
ModuleNotFoundError: No module named 'requests'
This is my import,
import requests

Related

MailInaBox config issue (from expiringdict import ExpiringDict)

So i recently upgraded my mailinabox installation and after that when I try to start the mailinabox service I get this error on the console
File "/root/mailinabox/management/auth.py",
from expiringdict import ExpiringDict
ModuleNotFoundError: No module named 'expiringdict'
I have tried and installed the modules manually using pip but it just doesn't work

Encountering 'urlparse module not found' error while importing googleanalytics library in Jupyter notebook

I am working on a project where I need to use the Google Analytics API to extract data into a python notebook.
I installed the googleanalytics library using:
!pip install googleanalytics
and it successfully installed.
Then I tried importing the library using:
import googleanalytics as ga
but it gives me a ModuleNotFound error which shows:
ModuleNotFoundError: No module named 'urlparse'
I then checked which library urlparse belongs to and found that it is a part of urllib3 library. So I tried installing that library but I got a message that it is already installed.
So I separately tried importing urlparse to check if it works using:
from urllib.parse import urlparse
and it works.
In summary, the urlparse module is installed but when I import googleanalytics library, I get an error that says module is not found.
How can that be fixed?

Why isn't the requests library working after being installed?

I have imported the requests package (pip install requests) and it shows when I run pip list, but when I run code that uses import requests, it gives me the error "ModuleNotFoundError: No module named 'requests'". I've tried updating pip but so far nothing has worked.

Cannot import requests after using 'pip3 install requests'

I am trying to import 'requests' in my python code(Python 3.5.2). I did the following:
first downloaded get-pip.py, and install it using python shell
then in my cmd directory for scripts: C:\Users\Juan\AppData\Local\Programs\Python\Python35-32\Scripts>, I typed "pip3 install requests". I got no error message for this step, and no message telling me the installation is successful either.
However, when run my python code, still got error File "C:/pycode/dl_proxy3.py", line 2, in <module>
import requests
ImportError: No module named 'requests'
Can't figure out what's the problem. Why the requests module still not installed.

ImportError: No module named 'googlevoice'

python noob here. Just start picking up python few weeks ago and currently need some help. I have 3.3.4 python for windows 7 and I tried running this:
import urllib.request
from googlevoice import Voice
from googlevoice.util import input
import time
File "<pyshell#0>", line 1, in <module>
from googlevoice import Voice
ImportError: No module named 'googlevoice'
so I figured. no big deal, I just need to install the module. I obtained a setup.py file from the link below and ran the file in different directories. Then tried " import googlevoice" but still doesn't work. The github link isn't too helpful, in terms of installing this module. Please help? I think I just have not learned how to install modules properly. Last time it took me a while to install pygame module, but i think it was because of directory issues at first.
https://pygooglevoice.googlecode.com/hg/
http://sphinxdoc.github.io/pygooglevoice/examples.html
To install the PyGoogleVoice, you need to download the whole archive and execute:
python setup.py install
If you have pip install, you can also run pip install pygooglevoice, or easy_install pygooglevoice with EasyInstall, without having to download the source code.

Categories