summaryrefslogtreecommitdiffstats
path: root/Doc/library/wsgiref.rst
diff options
context:
space:
mode:
authorSenthil Kumaran <senthil@uthcode.com>2011-05-11 14:34:59 (GMT)
committerSenthil Kumaran <senthil@uthcode.com>2011-05-11 14:34:59 (GMT)
commit57e6eac9056982bc6f4f18da0b6efacd1a19e3ae (patch)
tree2bc1b21f3e53b3a124f176d48354d9034639df09 /Doc/library/wsgiref.rst
parentdd2e94d80c4f291a7d382db5756efd8ec26aa9e7 (diff)
downloadcpython-57e6eac9056982bc6f4f18da0b6efacd1a19e3ae.zip
cpython-57e6eac9056982bc6f4f18da0b6efacd1a19e3ae.tar.gz
cpython-57e6eac9056982bc6f4f18da0b6efacd1a19e3ae.tar.bz2
Issue #11968 - the start_response header values in wsgiref shoudl be str not
bytes. The PEP-0333 says that and test_wsgiref follows the same. Updated docs accordingly.
Diffstat (limited to 'Doc/library/wsgiref.rst')
-rw-r--r--Doc/library/wsgiref.rst12
1 files changed, 6 insertions, 6 deletions
diff --git a/Doc/library/wsgiref.rst b/Doc/library/wsgiref.rst
index 3969ea4..1fd3451 100644
--- a/Doc/library/wsgiref.rst
+++ b/Doc/library/wsgiref.rst
@@ -122,8 +122,8 @@ parameter expect a WSGI-compliant dictionary to be supplied; please see
def simple_app(environ, start_response):
setup_testing_defaults(environ)
- status = b'200 OK'
- headers = [(b'Content-type', b'text/plain; charset=utf-8')]
+ status = '200 OK'
+ headers = [('Content-type', 'text/plain; charset=utf-8')]
start_response(status, headers)
@@ -414,8 +414,8 @@ Paste" library.
# Our callable object which is intentionally not compliant to the
# standard, so the validator is going to break
def simple_app(environ, start_response):
- status = b'200 OK' # HTTP Status
- headers = [(b'Content-type', b'text/plain')] # HTTP Headers
+ status = '200 OK' # HTTP Status
+ headers = [('Content-type', 'text/plain')] # HTTP Headers
start_response(status, headers)
# This is going to break because we need to return a list, and
@@ -754,8 +754,8 @@ This is a working "Hello World" WSGI application::
# is a dictionary containing CGI-style envrironment variables and the
# second variable is the callable object (see PEP 333).
def hello_world_app(environ, start_response):
- status = b'200 OK' # HTTP Status
- headers = [(b'Content-type', b'text/plain; charset=utf-8')] # HTTP Headers
+ status = '200 OK' # HTTP Status
+ headers = [('Content-type', 'text/plain; charset=utf-8')] # HTTP Headers
start_response(status, headers)
# The returned object is going to be printed