This commit is contained in:
Eden Kirin
2025-09-20 23:03:10 +02:00
commit 5f61822946
5 changed files with 15 additions and 0 deletions

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
__pycache__

9
README.md Normal file
View File

@ -0,0 +1,9 @@
```
python main.py
Traceback (most recent call last):
File "/home/eden/tmp/init_import_test/main.py", line 1, in <module>
from lib.some_class import SomeClass
File "/home/eden/tmp/init_import_test/lib/__init__.py", line 1, in <module>
raise Exception()
Exception
```

1
lib/__init__.py Normal file
View File

@ -0,0 +1 @@
raise Exception()

1
lib/some_class.py Normal file
View File

@ -0,0 +1 @@
class SomeClass: ...

3
main.py Normal file
View File

@ -0,0 +1,3 @@
from lib.some_class import SomeClass
c = SomeClass()