I have the following folder structure
project_folder/pyutils/__init__.pyscript1.pyscript2.py lambdas/__init__.pylambda_script1.pylambda_script2.pylambda_tests/__init__.pylambda_test1.py
Within lambda_test1.py
I have the following attempts
from lambdas.lambda_script1 import * # errors saying no module named lambdas
from .lambdas.lambda_script1 import * # errors saying ModuleNotFoundError: No module named '__main__.lambdas'; '__main__' is not a package
from ..lambdas.lmabda_script1 import * # errors saying tried to import above top level path
I'm trying to run my tests from the project folder with a command like
python pyutils/lambda_tests/lambda_test1.py
But none of the options seem to work
If I run IPython
from within the pyutils
folder and run from lambdas.lambda_script1 import *
it works. Is this a python path problem?
I also tried adding an __init__.py at the project folder and it still didn't work