On 5/3/07, Brian Blais <[EMAIL PROTECTED]> wrote:
> Carlos Hanson wrote:
> > It looks like you need __init__.py in MyPackage. Then you can import
> > starting with MyPackage. For example, you might use one of the
> > following:
> >
> > import MyPackage
> > from MyPackage.Common import *
> >
En Thu, 03 May 2007 12:41:00 -0300, Brian Blais <[EMAIL PROTECTED]>
escribió:
> I am trying to organize some of my code, and am having a little trouble
> with the import logic. I find I often have something like:
>
> MyPackage/
> Part1/ # wants to use functions in Common/
> __init__
Carlos Hanson wrote:
> It looks like you need __init__.py in MyPackage. Then you can import
> starting with MyPackage. For example, you might use one of the
> following:
>
> import MyPackage
> from MyPackage.Common import *
> etc
>
that means that MyPackage must be in the sys path too?
On May 3, 8:41 am, Brian Blais <[EMAIL PROTECTED]> wrote:
> Hello,
>
> I am trying to organize some of my code, and am having a little trouble with
> the
> import logic. I find I often have something like:
>
> MyPackage/
> Part1/ # wants to use functions in Common/
> __init__.py # does