##// END OF EJS Templates
vcs: Include reason phrase from VCSServer into HTTP status string.
Martin Bornhold -
r977:ed0fd60b default
parent child Browse files
Show More
@@ -80,8 +80,6 b' class VcsHttpProxy(object):'
80 repo_name, url)
80 repo_name, url)
81
81
82 def __call__(self, environ, start_response):
82 def __call__(self, environ, start_response):
83 status = '200 OK'
84
85 config = msgpack.packb(self._config)
83 config = msgpack.packb(self._config)
86 request = webob.request.Request(environ)
84 request = webob.request.Request(environ)
87 request_headers = request.headers
85 request_headers = request.headers
@@ -115,8 +113,11 b' class VcsHttpProxy(object):'
115 if not wsgiref.util.is_hop_by_hop(h)
113 if not wsgiref.util.is_hop_by_hop(h)
116 ]
114 ]
117
115
118 # TODO: johbo: Better way to get the status including text?
116 # Build status argument for start_reponse callable.
119 status = str(response.status_code)
117 status = '{status_code} {reason_phrase}'.format(
118 status_code=response.status_code,
119 reason_phrase=response.reason)
120
120 start_response(status, response_headers)
121 start_response(status, response_headers)
121 return _maybe_stream(response)
122 return _maybe_stream(response)
122
123
General Comments 0
You need to be logged in to leave comments. Login now