Hello Bert,

Sorry for the late reply.

On Nov 22, 3:50 pm, Bert Heymans <[EMAIL PROTECTED]> wrote:
> Installing went fine (sudo python setup.py install), and the tests are
> OK (python setup.py test) but somehow I can't access the django
> package. This is the output I get in a terminal:
>
> Python 2.5 (r25:51918, Sep 19 2006, 08:49:13)
> [GCC 4.0.1 (Apple Computer, Inc. build 5341)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.>>> 
> from pyamf.gateway.django import DjangoGateway
>
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File "pyamf/gateway/django.py", line 37, in <module>
>     _thismodule = sys.modules['django']
> KeyError: 'django'>>> import pyamf.gateway
> >>> dir(pyamf.gateway)
>
> ['BaseGateway', 'ServiceRequest', 'ServiceWrapper', '__builtins__',
> '__doc__', '__file__', '__name__', '__path__', 'remoting', 'sys',
> 'traceback', 'types']
>
> You see, no 'django' in the list. Anyway, if I look at the sourcecode
> it's all there in the gateway package there's 'django', 'twisted' and
> 'wsgi'.

It is finding the pyamf.gateway.django package allright, the line it
fails on is in that module. Is Django on your python path?

It is due to a trick we have to use to both call our subpackage
"django" and still be able to import the real (top-level) django
package. The trick is to mess with sys.modules a bit (see the code).

Please stop by on the pyamf developers list and post us steps to
reproduce this and we'll sort it out.

cheers,
Arnar
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to