Structure of packages

Scott David Daniels Scott.Daniels at Acm.Org
Thu Jan 10 00:28:15 EST 2008


Ben Fisher wrote:
> I am trying to learn the best way to do intra-package references. My
> package looks like this: 
...
> I had thought that "from PackageName.b import *" would work....
In an attempt to hand oyu a net, rather than an answer:
Try using command line:

    python -v whatever.py

You can see all the imports that are done and in what order.

Also realize that import a file executes it, so you can sprinkle
prints at points where you are confused.

--Scott David Daniels
Scott.Daniels at Acm.Org



More information about the Python-list mailing list