Message87190
While testing the following script on Jython 2.5b4 I noticed it returned
SERVER_SOFTWARE = 'WSGIServer/0.1 Python/2.5b4+' instead of the expected
'WSGIServer/0.1 Jython/2.5b4+'. This is because the word 'Python' is
hardcoded in simple_server.py; "sys_version = "Python/" +
sys.version.split()[0]". I suggest using the real name of the runtime
instead of hardcoding it.
from wsgiref.simple_server import make_server, demo_app
httpd = make_server('', 8000, demo_app)
print "Serving HTTP on port 8000..."
# Respond to requests until process is killed
httpd.serve_forever()
# Alternative: serve one request, then exit
httpd.handle_request() |
|
Date |
User |
Action |
Args |
2009-05-04 23:11:06 | thijs | set | recipients:
+ thijs |
2009-05-04 23:11:05 | thijs | set | messageid: <1241478665.1.0.327455115942.issue5931@psf.upfronthosting.co.za> |
2009-05-04 23:11:02 | thijs | link | issue5931 messages |
2009-05-04 23:10:59 | thijs | create | |
|