[Python] ModuleNotFoundError: No module named - Even after adding module path to sys.path

Discussão em 'Python' iniciado por Stack, Abril 17, 2025.

  1. Stack

    Stack Membro Participativo

    So I probably am missing something simple, but I have been messing around with creating my own modules/packages, but when I try to import them in other code...it does not work even after adding the package path to my sis.path. See below for an example:

    import sys
    sys.path.insert(0,"C:/Scripts/Google/googleFunctions")
    from googleFunctions import MoveExtracts,PurgeExtracts


    After running the code, I get the following error:

    ModuleNotFoundError: No module named 'googleFunctions'


    I am very new to this, so I am clearly doing something wrong, probably something simple. I read something about having to have a init.py file in the package directory with your modules, but this does not seem to fix the issue. Thoughts?

    Continue reading...

Compartilhe esta Página