NameError in cross imports of modules
fredrik at effbot.org
Sat Feb 3 21:14:21 CET 2001
Pearu Peterson wrote:
> Note: I am not interested in converting the 'from-import' statements to
> 'import' statements,
> This behavior is well-known and has, roughly speaking, the following
> >>> from A import * --- imports also module B but only "partly": module
> A is not imported to module B.
> >>> from B import * --- nothing is done because module B is already in
> >>> reload(sys.modules['B']) --- is needed in order to fix the
> NameError: module B will be imported
if you don't understand how things work today, are you
really the right person to suggest changes?
More information about the Python-list