[WSGI] James will kein reload...
Verfasst: Dienstag 17. Januar 2006, 20:16
Ich hab blackbirds [wiki]James[/wiki] getestet, aber bei mir will er keinen reload der App machen. Ich hab ein frisches SVN checkout gemacht...
So sieht meine App aus:
So sieht meine App aus:
Code: Alles auswählen
#!/usr/bin/python
# -*- coding: UTF-8 -*-
#~ import cgitb;cgitb.enable()
import time
class HelloWorldApplication(object):
def __init__(self, environ, start_response):
self.environ = environ
self.start_response = start_response
def __iter__(self):
self.start_response('200 OK', [('Content-Type', 'text/plain')])
yield time.time()
yield 'Hallo Welt <br>'
yield 'Hallo Welt2'
app = HelloWorldApplication
if __name__ == '__main__':
from james import WSGIServer
server = WSGIServer(
applications={'/': app},
autoreload = True,
)
server.run()