i am trying to import a module within a module and then access the lower level module from the top, however it is not available. is this normal behaviour?
# caller.py
import first
print second.some_var
# first.py
import second
# second.py
some_var = 1
running caller.py gives error
NameError: name 'second' is not defined
do i have to import second within caller.py? this seems counter-intuitive to me.
firstandsecondneed access tosome_var, you could createthirdmodule and putsome_varin there.