durusmail: quixote-users: Newbie Question - Quixote w/ Medusa - pythonpath issue?
debugging quixote applications
2004-09-20
2004-09-20
Re: debugging quixote applications
2004-09-21
2004-09-21
Quixote Application Skeleton? Best Practices?
Newbie Question - Quixote w/ Medusa - pythonpath issue?
2004-09-21
2004-09-21
Newbie Question - Quixote w/ Medusa - pythonpath issue?
rtjohan@syspres.com
2004-09-20
Hi,

I decided to give the Quixote Skeleton documentation
(http://www.rexx.com/~dkuhlman/quixote_skeleton.html) a try. Trying to
get Quixote skeleton to work with medusa.

Getting an "ImportError: No module named skeleton.ui". (Full trace
below)

I kept the directory name as skeleton so there wouldn't be any need to
change the server-medusa.py.

/Users/richard/Desktop/dev/workspace/skeleton/services
/Users/richard/Desktop/dev/workspace/skeleton/ui
/Users/richard/Desktop/dev/workspace/skeleton/scripts
/Users/richard/Desktop/dev/workspace/skeleton/scripts/server-medusa.py

The documentation mentions to set PYTHONPATH to skeleton's parent
directory, so now env set to:
PYTHONPATH=/Users/richard/Desktop/dev/workspace. Is the PYTHONPATH
being set incorrectly?

Anyone have any hints how to overcome this seemingly issue or point me
to some more detailed documentation on how quixote handles paths and
contexts?

Thanks in advance,
Richard

----------------------------Trace----------------------------
[G4:workspace/skeleton/scripts] richard# python server-medusa.py
Now serving the skeleton services on port 80
info: Medusa (V1.11) started at Mon Sep 20 15:23:44 2004
         Hostname: localhost
         Port:80

Traceback (most recent call last):
   File "server-medusa.py", line 164, in ?
     main()
   File "server-medusa.py", line 158, in main
     start_server(port)
   File "server-medusa.py", line 100, in start_server
     publisher = MyPublisher('skeleton.ui')
   File "server-medusa.py", line 59, in __init__
     Publisher.__init__(self, root_namespace, config)
   File "/opt/local/lib/python2.3/site-packages/quixote/publish.py",
line 107, in __init__
     self.root_namespace = _get_module(root_namespace)
   File "/opt/local/lib/python2.3/site-packages/quixote/publish.py",
line 32, in _get_module
     __import__(name)
ImportError: No module named skeleton.ui
Exception exceptions.AttributeError: "MyPublisher instance has no
attribute 'container'" in > ignored


reply