>
> Tried with uwsgi 0.9.9.2 from pypi and then 1.0-rc6 from tarball, in
> a virtualenv of Debian's Python 2.5.2. I didn't try gdb in this setup.
>
> Contents of dmwsgi.py are:
>
> import django.core.handlers.wsgi
>
> application = django.core.handlers.wsgi.WSGIHandler()
>

Fun enough, i cannot reproduce the error:

django-admin startproject foobar
# vim foo.py
from django.core.handlers.wsgi import WSGIHandler

application = WSGIHandler()

import cStringIO
input = cStringIO.StringIO()
errors = cStringIO.StringIO()
print 'TESTING: calling application'
def noop(status, hh, exc_info=None):
    pass

application(
{
  'CONTENT_LENGTH': '',
  'CONTENT_TYPE': '',
  'DOCUMENT_ROOT': '/usr/local/nginx/html',
  'HTTP_HOST': 'test.datamarket.com',
  'PATH_INFO': '/__ping__',
  'REMOTE_ADDR': '157.157.92.142',
  'REMOTE_PORT': '65420',
  'REQUEST_METHOD': 'GET',
  'REQUEST_URI': '/__ping__',
  'SERVER_NAME': 'test.datamarket.com',
  'SERVER_PORT': '80',
  'SERVER_PROTOCOL': 'HTTP/1.1',
  'uwsgi.node': 'itchy',
  'uwsgi.version': '1.0-dev',
  'wsgi.multiprocess': True,
  'wsgi.multithread': False,
  'wsgi.run_once': False,
  'wsgi.url_scheme': 'http',
  'wsgi.version': (1, 0),
  'wsgi.input': input,
  'wsgi.errors': errors,
}, noop)

./uwsgi -s :3031 -M -p 4 --env DJANGO_SETTINGS_MODULE=foobar.settings -w foo

*** Starting uWSGI 1.0-dev-1691 (32bit) on [Mon Nov 21 11:17:36 2011] ***
compiled with version: 4.6.2 on 21 November 2011 11:08:29
current working directory: /root/uwsgi
detected binary path: /root/uwsgi/uwsgi
uWSGI running as root, you can use --uid/--gid/--chroot options
*** WARNING: you are running uWSGI as root !!! (use the --uid flag) ***
your memory page size is 4096 bytes
*** RRDtool library available at 0x9badf88 ***
uwsgi socket 0 bound to TCP address :3031 fd 3
Python version: 2.7.2+ (default, Oct  4 2011, 16:09:31)  [GCC 4.6.1]
Python main interpreter initialized at 0x9bb4448
your server socket listen backlog is limited to 100 connections
*** Operational MODE: preforking ***
TESTING: calling application
WSGI application 0 (mountpoint='') ready on interpreter 0x9bb4448 pid:
11609 (default app)
*** uWSGI is running in multiple interpreter mode ***
spawned uWSGI master process (pid: 11609)
spawned uWSGI worker 1 (pid: 11610, cores: 1)
spawned uWSGI worker 2 (pid: 11611, cores: 1)
spawned uWSGI worker 3 (pid: 11612, cores: 1)
spawned uWSGI worker 4 (pid: 11613, cores: 1)
---------


Are you sure you are not calling any uwsgi api function from your
/__ping__ view ?

-- 
Roberto De Ioris
http://unbit.it
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to