[Python] python cannot find module that is installed on windows

Discussão em 'Python' iniciado por Stack, Março 7, 2025.

  1. Stack

    Stack Membro Participativo

    I have installed the requests module

    C:\Python34\Scripts\easy_install.exe requests


    i got to the folder location

    C:\Python34\Lib\site-packages\requests-2.13.0-py3.4.egg\requests


    I have a path variable in system

    C:\Python34\Lib\site-packages


    yet when i run my script

    C:\Users\beast\Desktop>update.py


    I get the error No module named 'requests'

    Traceback (most recent call last):
    File "C:\Users\beast\Desktop\plex_playlist_update.py", line 17, in <module>
    import requests
    ModuleNotFoundError: No module named 'requests'


    I tried installing using pip just in case

    python -m pip install requests
    Requirement already satisfied: requests in c:\python34\lib\site-packages\requests-2.13.0-py3.4.egg


    I am new to python and I cant find an answer anywhere.

    UPDATE:

    I found a command to check my python search location.

    C:\Users\beast\Desktop>python -c "import site; print(site.getsitepackages())"
    ['C:\\Python34', 'C:\\Python34\\lib\\site-packages']


    I think it has to do with C:\Python34 vs C:\python34? How do i check or fix this?

    Continue reading...

Compartilhe esta Página