How do I structure my Python project to allow named modules to be imported from sub directories
问题 This is my directory structure: Projects + Project_1 + Project_2 - Project_3 - Lib1 __init__.py # empty moduleA.py - Tests __init__.py # empty foo_tests.py bar_tests.py setpath.py __init__.py # empty foo.py bar.py Goals: Have an organized project structure Be able to independently run each .py file when necessary Be able to reference/import both sibling and cousin modules Keep all import/from statements at the beginning of each file. I Achieved #1 by using the above structure I've mostly