]> granicus.if.org Git - python/commitdiff
fixed #5801: removed spurious empty lines in wsgiref
authorTarek Ziadé <ziade.tarek@gmail.com>
Tue, 23 Feb 2010 05:53:05 +0000 (05:53 +0000)
committerTarek Ziadé <ziade.tarek@gmail.com>
Tue, 23 Feb 2010 05:53:05 +0000 (05:53 +0000)
Lib/wsgiref/handlers.py
Lib/wsgiref/headers.py
Lib/wsgiref/simple_server.py
Lib/wsgiref/util.py
Misc/NEWS

index aa8163b6713bb559ef3548276a6b1dca488a2db1..fcb8e239373bed2a34dffc591c248d5b88c8966a 100644 (file)
@@ -39,7 +39,6 @@ def format_date_time(timestamp):
     )
 
 
-
 class BaseHandler:
     """Manage the invocation of a WSGI application"""
 
@@ -74,13 +73,6 @@ class BaseHandler:
     headers = None
     bytes_sent = 0
 
-
-
-
-
-
-
-
     def run(self, application):
         """Invoke the application"""
         # Note to self: don't move the close()!  Asynchronous servers shouldn't
@@ -359,15 +351,6 @@ class BaseHandler:
         raise NotImplementedError
 
 
-
-
-
-
-
-
-
-
-
 class SimpleHandler(BaseHandler):
     """Handler that's just initialized with streams, environment, etc.
 
@@ -433,23 +416,6 @@ class BaseCGIHandler(SimpleHandler):
     origin_server = False
 
 
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
 class CGIHandler(BaseCGIHandler):
 
     """CGI-based invocation via sys.stdin/stdout/stderr and os.environ
@@ -474,20 +440,3 @@ class CGIHandler(BaseCGIHandler):
             self, sys.stdin, sys.stdout, sys.stderr, dict(os.environ.items()),
             multithread=False, multiprocess=True
         )
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
index 6bd304ef97024786c4c9378a3e8a2c60e4653738..6c8c60c891355d68219c1a1022589fd639504dcf 100644 (file)
@@ -27,18 +27,6 @@ def _formatparam(param, value=None, quote=1):
         return param
 
 
-
-
-
-
-
-
-
-
-
-
-
-
 class Headers:
 
     """Manage a collection of HTTP response headers"""
@@ -76,10 +64,6 @@ class Headers:
         """
         return self.get(name)
 
-
-
-
-
     def has_key(self, name):
         """Return true if the message contains the header."""
         return self.get(name) is not None
@@ -118,9 +102,6 @@ class Headers:
         """
         return [k for k, v in self._headers]
 
-
-
-
     def values(self):
         """Return a list of all header values.
 
@@ -161,7 +142,6 @@ class Headers:
         else:
             return result
 
-
     def add_header(self, _name, _value, **_params):
         """Extended header setting.
 
@@ -187,19 +167,3 @@ class Headers:
             else:
                 parts.append(_formatparam(k.replace('_', '-'), v))
         self._headers.append((_name, "; ".join(parts)))
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
index 1b0a4b220980d51f8d24cfd81ad35ab0a22e7bcf..e6a385b03c74d3a63d2c34a9ab978ad9a2bf0301 100644 (file)
@@ -37,8 +37,6 @@ class ServerHandler(SimpleHandler):
 
 
 
-
-
 class WSGIServer(HTTPServer):
 
     """BaseHTTPServer that implements the Python WSGI protocol"""
@@ -68,18 +66,6 @@ class WSGIServer(HTTPServer):
 
 
 
-
-
-
-
-
-
-
-
-
-
-
-
 class WSGIRequestHandler(BaseHTTPRequestHandler):
 
     server_version = "WSGIServer/" + __version__
@@ -139,29 +125,6 @@ class WSGIRequestHandler(BaseHTTPRequestHandler):
 
 
 
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
 def demo_app(environ,start_response):
     from StringIO import StringIO
     stdout = StringIO()
@@ -190,16 +153,3 @@ if __name__ == '__main__':
     import webbrowser
     webbrowser.open('http://localhost:8000/xyz?abc')
     httpd.handle_request()  # serve one request, then exit
-
-
-
-
-
-
-
-
-
-
-
-
-#
index 450a32fbce5647fa142a23a7f4f1924abfed8cf1..39e05f15ab59716e70fc586ea2991be0bfbdcfac 100644 (file)
@@ -32,13 +32,6 @@ class FileWrapper:
             return data
         raise StopIteration
 
-
-
-
-
-
-
-
 def guess_scheme(environ):
     """Return a guess for whether 'wsgi.url_scheme' should be 'http' or 'https'
     """
@@ -161,7 +154,6 @@ def setup_testing_defaults(environ):
 
 
 
-
 _hoppish = {
     'connection':1, 'keep-alive':1, 'proxy-authenticate':1,
     'proxy-authorization':1, 'te':1, 'trailers':1, 'transfer-encoding':1,
@@ -171,35 +163,3 @@ _hoppish = {
 def is_hop_by_hop(header_name):
     """Return true if 'header_name' is an HTTP/1.1 "Hop-by-Hop" header"""
     return _hoppish(header_name.lower())
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
index c3cf9b52a55e28f5a2f4bc0d7b5b7ba931ee037d..1345a56b6e40a50db30b31edbc31d7ec3bb08c4c 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -48,6 +48,8 @@ Library
 - Issue #7588: ``unittest.TextTestResult.getDescription`` now includes the test
   name in failure reports even if the test has a docstring.
 
+- Issue #5801: removed spurious empty lines in wsgiref.
+
 Extension Modules
 -----------------