Hi,

Since this is Python3, bytes must be returned:

  s = "Running " + str(sys.version_info)
  return s.encode("utf-8")

Should that be it?
Jens


On Wed, Feb 18, 2015 at 06:37:20AM +0100, Jens Tröger wrote:
> Hi,
> 
> I'm trying out uwsgi to see if it solves my problem of running different
> webapps and Python versions through a single Apache instance.  It
> seems to, somehow.  Requests make it through Apache and arrive at my
> uwsgi server.  The server is set up like so:
> 
> [uwsgi]
> master = true
> socket = localhost:3101
> plugins = python34
> virtualenv = /path/to/venv
> wsgi-file = /path/to/venv/test-wsgi.py
> processes = 1
> threads = 2
> 
> and my test script is simple:
> 
> import sys
> def application(environ, start_response):
>     start_response('200 OK', [('Content-Type', 'text/plain')])
>     return "Running " + str(sys.version_info)
> 
> Everything seems to work fine, except that the responses from the server
> are empty. There is output from uwsgi though:
> 
> [pid: 32275|app: 0|req: 1/1] 73.193.3.79 () {58 vars in 1241 bytes} [Wed Feb 
> 18 03:29:53 2015] GET / => generated 0 bytes in 0 msecs (HTTP/1.1 200) 1 
> headers in 45 bytes (83 switches on core 0)
> ...
> 
> What's missing here?
> Thanks, Jens

-- 
Jens Tröger
http://savage.light-speed.de/
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to