I have this structure:
. └── module ├── __init__.py └── submodule ├── __init__.py ├── foo.py └── bar.py
In module.submodule.__init__.py , I have this:
import foo import bar
In module.submodule.foo.py , I have this:
import very_heavy_third_party_module as vhtpm ...
I would like to import only bar , but I slowed down on foo (suppose there is an ugly time.sleep(3) in foo and module/__init__.py ).
So, my goal is to write this below without slowing down the other parts of my module:
from module.submodule.bar import saybar saybar()
How do I import saybar into my bar submodule?
nowox source share