The use of
from . import baz
instead of
import foo.bar.baz
is not practicable/considerable:
It is not possible to use the "if __name__ == '__main__'" -feature then to call that script also directly. It breaks with:
"ValueError: Attempted relative import in non-package"
The use of
from . import baz
instead of
import foo.bar.baz
is not practicable/ considerable:
It is not possible to use the "if __name__ == '__main__'" -feature then to call that script also directly. It breaks with:
"ValueError: Attempted relative import in non-package"
@asmeurer
yes, i watched the whole tutorial