ladon + uwsgi: unable to load app

Asked by paolinux79 on 2013-06-24

Hi,
I am using to publish some API (soap) over the internet.
I would like to use nginx + uwsgi but i am in trouble:
I get this output browsing to the page:

Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/ladon/server/wsgi_application.py", line 332, in __call__
    self.import_services(self.service_list)
  File "/usr/local/lib/python2.7/dist-packages/ladon/server/wsgi_application.py", line 288, in import_services
    __import__(service)
ImportError: No module named serverL

My CLI is:
uwsgi -s 127.0.0.1:7777 --logto ~/uwsgi.log --wsgi-file /path/scripts/handler.py

handler.py contains:
from ladon.server.wsgi import LadonWSGIApplication
from os.path import abspath,dirname

application = LadonWSGIApplication('serverL','/path/script/src')

from ladon.server.wsgi import LadonWSGIApplication
from os.path import abspath,dirname
application = LadonWSGIApplication('serverL')

and my tree in /path/script:
.
├── handler.py
├── src
│   ├── serverL.py

Thanks in advance

Question information

Language:
English Edit question
Status:
Solved
For:
ladon Edit question
Assignee:
No assignee Edit question
Solved by:
paolinux79
Solved:
2013-06-25
Last query:
2013-06-25
Last reply:
paolinux79 (paolo-bert-w) said : #1

solved in this way:
uwsgi --pythonpath /path/to/script/src/ -s 127.0.0.1:7777 --wsgi-file handler.py
thanks to:
 http://stackoverflow.com/questions/17293374/ladon-uwsgi-unable-to-load-app