I have a simple directory structure like so:
lib/
dir1/
__init__.py
dir2/
__init__.py
file1.py
file2.py
main.py
file1.py
imports file2.py
main.py
does from dir1.dir2.file1 import *
. However, when I run main.py
I get the following error:
No module named 'file2'
When I run file
from dir2
it's fine. How does the python3 import system work?