Also, input is bytes, not unicode...
This commit is contained in:
parent
90ea9f78d1
commit
3a0fc6739a
|
@ -292,7 +292,7 @@ server.
|
||||||
|
|
||||||
def run_with_cgi(application):
|
def run_with_cgi(application):
|
||||||
environ = {k: unicode_to_wsgi(v) for k,v in os.environ.items()}
|
environ = {k: unicode_to_wsgi(v) for k,v in os.environ.items()}
|
||||||
environ['wsgi.input'] = sys.stdin
|
environ['wsgi.input'] = sys.stdin.buffer
|
||||||
environ['wsgi.errors'] = sys.stderr
|
environ['wsgi.errors'] = sys.stderr
|
||||||
environ['wsgi.version'] = (1, 0)
|
environ['wsgi.version'] = (1, 0)
|
||||||
environ['wsgi.multithread'] = False
|
environ['wsgi.multithread'] = False
|
||||||
|
|
Loading…
Reference in New Issue