Remove path_info from request message format

This commit is contained in:
Andrew Godwin 2015-11-06 13:35:33 +01:00
parent c937c4da6d
commit 5106c7822c
2 changed files with 2 additions and 3 deletions

View File

@ -15,7 +15,6 @@ def encode_request(request):
"cookies": request.COOKIES,
"meta": {k: v for k, v in request.META.items() if not k.startswith("wsgi")},
"path": request.path,
"path_info": request.path_info,
"method": request.method,
"reply_channel": request.reply_channel,
}
@ -33,8 +32,9 @@ def decode_request(value):
request.META = value['meta']
request.path = value['path']
request.method = value['method']
request.path_info = value['path_info']
request.reply_channel = value['reply_channel']
# We don't support non-/ script roots
request.path_info = value['path']
return request

View File

@ -38,7 +38,6 @@ Contains the following keys:
* cookies: Dict of cookies as {cookie_name: cookie_value} (names and values are strings)
* meta: Dict of HTTP headers and info as defined in the Django Request docs (names and values are strings)
* path: String, full path to the requested page, without query string or domain
* path_info: String, like ``path`` but without any script prefix. Often just ``path``.
* method: String, upper-cased HTTP method
Should come with an associated ``reply_channel`` which accepts HTTP Responses.