[Zope] Another import doesn't find the module
Stacy Roberts Ladnier
Stacy.Roberts@noaa.gov
Wed, 28 May 2003 12:06:32 -0500
I have tried both. The name of the class I am trying to import is
profile. So I put
from Products.Resources.FGDC import profile
and I get 'cannot import name profile'
When I try
from Products.Resources.FGDC import *
I get 'no module named FGDC'. But I promise there is and there is a
__init__ file there this time. This module is used from many other
parts in my product.
I have the PYTHONPATH right and an __init__ in both the FGDC and
extensions folders. I am at a loss for what is happening here.
Any help is appreciated, this is the last task before deployment.
Stacy
----- Original Message -----
From: Dylan Reinhardt <zope@dylanreinhardt.com>
Date: Wednesday, May 28, 2003 10:38 am
Subject: Re: [Zope] Another import doesn't find the module
> This is a different problem. I think what you want is:
>
> import * from Products.Resources.FGDC.profile
>
> or
>
> from Products.Resources.FGDC.profile import NAMES_GO_HERE
>
> HTH,
>
> Dylan
>
>
> On Wed, 2003-05-28 at 07:33, Stacy Roberts Ladnier wrote:
> > I am attempting to import another class for use and Zope now
> > complains 'cannot import name profile'.
> >
> >
> > My Product structure in a bit more detail is:
> >
> > Products
> > - Resources
> > -FGDC
> > -__init__.py
> > -profile.py
> > -BIO
> > -scripts
> > -script1.py
> > -dtml
> > -www
> > -extensions
> > -DISTINFO.py which contains a class of the same name
> >
> > In DISTINFO.py, I have an import statement like this:
> > from Products.Resources.FGDC import profile
> >
> > Can someone please tell me what I am doing wrong here??
> >
> > Thanks in advance,
> > Stacy
> >
> >
> >
> >
> > _______________________________________________
> > Zope maillist - Zope@zope.org
> > http://mail.zope.org/mailman/listinfo/zope
> > ** No cross posts or HTML encoding! **
> > (Related lists -
> > http://mail.zope.org/mailman/listinfo/zope-announce
> > http://mail.zope.org/mailman/listinfo/zope-dev )
>
>