Benjamin Kaplan wrote:
On Sun, Nov 8, 2009 at 9:38 PM, Alan Harris-Reid
wrote:
In the Python.org 3.1 documentation (section 20.4.6), there is a simple
"Hello World" WSGI application which includes the following method...
def hello_world_app(environ, start_response):
status ='200 OK' # HTTP
Gerard Flanagan wrote:
Alan Harris-Reid wrote:
In the Python.org 3.1 documentation (section 20.4.6), there is a
simple “Hello World” WSGI application which includes the following
method...
def hello_world_app(environ, start_response):
status ='200 OK' # HTTP Status
headers =(b'Content-type',
Alan Harris-Reid wrote:
In the Python.org 3.1 documentation (section 20.4.6), there is a simple
“Hello World” WSGI application which includes the following method...
def hello_world_app(environ, start_response):
status = b'200 OK' # HTTP Status
headers = [(b'Content-type', b'text/plain; charset
Alan Harris-Reid writes:
> From what I can gather from the documentation the b prefix represents
> a bytes literal
Yes. In Python 3 there are two types with similar-looking literal
syntax: ‘str’ and ‘bytes’. The types are mutually incompatible (though
they can be explicitly converted).
http
On Sun, Nov 8, 2009 at 9:38 PM, Alan Harris-Reid
wrote:
> In the Python.org 3.1 documentation (section 20.4.6), there is a simple
> “Hello World” WSGI application which includes the following method...
>
> def hello_world_app(environ, start_response):
> status = b'200 OK' # HTTP Status
> headers =
In the Python.org 3.1 documentation (section 20.4.6), there is a simple
“Hello World” WSGI application which includes the following method...
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