[Python-checkins] r78367 - in python/trunk: Lib/wsgiref/handlers.py Lib/wsgiref/headers.py Lib/wsgiref/simple_server.py Lib/wsgiref/util.py Misc/NEWS

tarek.ziade python-checkins at python.org
Tue Feb 23 06:53:05 CET 2010


Author: tarek.ziade
Date: Tue Feb 23 06:53:05 2010
New Revision: 78367
Log:
fixed #5801: removed spurious empty lines in wsgiref
Modified:
 python/trunk/Lib/wsgiref/handlers.py
 python/trunk/Lib/wsgiref/headers.py
 python/trunk/Lib/wsgiref/simple_server.py
 python/trunk/Lib/wsgiref/util.py
 python/trunk/Misc/NEWS
Modified: python/trunk/Lib/wsgiref/handlers.py
==============================================================================
--- python/trunk/Lib/wsgiref/handlers.py	(original)
+++ python/trunk/Lib/wsgiref/handlers.py	Tue Feb 23 06:53:05 2010
@@ -39,7 +39,6 @@
 )
 
 
-
 class BaseHandler:
 """Manage the invocation of a WSGI application"""
 
@@ -74,13 +73,6 @@
 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 @@
 raise NotImplementedError
 
 
-
-
-
-
-
-
-
-
-
 class SimpleHandler(BaseHandler):
 """Handler that's just initialized with streams, environment, etc.
 
@@ -433,23 +416,6 @@
 origin_server = False
 
 
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
 class CGIHandler(BaseCGIHandler):
 
 """CGI-based invocation via sys.stdin/stdout/stderr and os.environ
@@ -474,20 +440,3 @@
 self, sys.stdin, sys.stdout, sys.stderr, dict(os.environ.items()),
 multithread=False, multiprocess=True
 )
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
Modified: python/trunk/Lib/wsgiref/headers.py
==============================================================================
--- python/trunk/Lib/wsgiref/headers.py	(original)
+++ python/trunk/Lib/wsgiref/headers.py	Tue Feb 23 06:53:05 2010
@@ -27,18 +27,6 @@
 return param
 
 
-
-
-
-
-
-
-
-
-
-
-
-
 class Headers:
 
 """Manage a collection of HTTP response headers"""
@@ -76,10 +64,6 @@
 """
 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 @@
 """
 return [k for k, v in self._headers]
 
-
-
-
 def values(self):
 """Return a list of all header values.
 
@@ -161,7 +142,6 @@
 else:
 return result
 
-
 def add_header(self, _name, _value, **_params):
 """Extended header setting.
 
@@ -187,19 +167,3 @@
 else:
 parts.append(_formatparam(k.replace('_', '-'), v))
 self._headers.append((_name, "; ".join(parts)))
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
Modified: python/trunk/Lib/wsgiref/simple_server.py
==============================================================================
--- python/trunk/Lib/wsgiref/simple_server.py	(original)
+++ python/trunk/Lib/wsgiref/simple_server.py	Tue Feb 23 06:53:05 2010
@@ -37,8 +37,6 @@
 
 
 
-
-
 class WSGIServer(HTTPServer):
 
 """BaseHTTPServer that implements the Python WSGI protocol"""
@@ -68,18 +66,6 @@
 
 
 
-
-
-
-
-
-
-
-
-
-
-
-
 class WSGIRequestHandler(BaseHTTPRequestHandler):
 
 server_version = "WSGIServer/" + __version__
@@ -139,29 +125,6 @@
 
 
 
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
 def demo_app(environ,start_response):
 from StringIO import StringIO
 stdout = StringIO()
@@ -190,16 +153,3 @@
 import webbrowser
 webbrowser.open('http://localhost:8000/xyz?abc')
 httpd.handle_request() # serve one request, then exit
-
-
-
-
-
-
-
-
-
-
-
-
-#
Modified: python/trunk/Lib/wsgiref/util.py
==============================================================================
--- python/trunk/Lib/wsgiref/util.py	(original)
+++ python/trunk/Lib/wsgiref/util.py	Tue Feb 23 06:53:05 2010
@@ -32,13 +32,6 @@
 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 @@
 
 
 
-
 _hoppish = {
 'connection':1, 'keep-alive':1, 'proxy-authenticate':1,
 'proxy-authorization':1, 'te':1, 'trailers':1, 'transfer-encoding':1,
@@ -171,35 +163,3 @@
 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())
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS	(original)
+++ python/trunk/Misc/NEWS	Tue Feb 23 06:53:05 2010
@@ -48,6 +48,8 @@
 - 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
 -----------------
 


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /