Skip to content

How to import custom Python modules to the config.py? #595

Answered by PeerBoerner1
Marlpzg asked this question in Q&A
Discussion options

You must be logged in to vote

This "module not found" is typically Python related and can happen for a variety of reasons, though it usually happens when your default directory is not what you think it is. One way to solve this problem is to set the PYTHONPATH environment variable to point to your project directory where all of your "main" python logic is stored. This will force python to check that directory for any modules and packages in its associated subdirectories. You must also ensure that your python package subdirectories have init.py files present (marking the directory as a module). These init.py files can be empty. Hope this helps.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Marlpzg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants