Newbie: module structure and import question
ziongmail-py at yahoo.com
Wed Jan 12 10:06:43 EST 2005
i have question on how to design a module structure.
for example, i have 3 files.
from myLib.ClassA import ClassA
a = classA()
from myLib.Base.BaseA import BaseA
if (__name__ == "__main__"):
print "test class A"
a = ClassA()
It's fine when i run main.py.
however when i run ClassA.py individually, it would fail in import
statment since the import path is incorrect.
I would like to know is something wrong in my design, or something i
Also, in practical usage, is that one class in one py file?
a python newbie
More information about the Python-list