My folder structure is
main/program.py
main/plugins/utils.py
main/plugins/plugin1/main.py
I'm using importlib.import_module( 'plugins.plugin1.main' ).my_class() to import a class from main.py in program.py. I'd like to import a class from utils.py in main.py. However, I can't see to use the same call.
I see a lot of references online to simply injecting a path into the system PATH variable to load a distant module, but I'd like to avoid that if possible and keep the environment as clean as I can. Is there any other good way to load that class?