summaryrefslogtreecommitdiff
path: root/webob/request.py
Commit message (Collapse)AuthorAgeFilesLines
* dont try to decode remote_userChris McDonough2012-01-281-3/+1
|
* give up on trying to encode header values when request.headers is usedChris McDonough2012-01-281-4/+7
|
* more spurious diff removalChris McDonough2012-01-281-8/+8
|
* add change notes, reduce spurious diffsChris McDonough2012-01-281-30/+28
|
* set deprecated properties on BaseRequest rather than LegacyRequest, use ↵Chris McDonough2012-01-281-12/+16
| | | | environ_getter for presumed-ascii-only settings
* bytesrequest renamed to legacyrequest... it no longer eagerly converts to ↵Chris McDonough2012-01-281-123/+83
| | | | bytes, it just presents the older native string api expected by existing systems. textrequest renamed to baserequest, it is the new default request type.. it no longer eagerly converts to text, either unless an encattr is named on the environ_decoder
* test textrequest and bytesrequest independentlyChris McDonough2012-01-281-9/+10
|
* use latin-1 as the default decoder/encoderChris McDonough2012-01-261-2/+2
|
* get rid of useless literalsChris McDonough2012-01-261-13/+5
|
* make charset a native string, make _content_type_raw an environ getter ↵Chris McDonough2012-01-261-13/+11
| | | | rather than environ decoder
* turn remote_user_encoding and url_encoding into environ_getters (adding ↵Chris McDonough2012-01-261-3/+3
| | | | webob.remote_user_encoding and webob.url_encoding vars to environ), fix _request_uri for Python 3, improve _abs_headerlist, dont decode scheme when looking up
* fix EnvironHeaders class to do encoding and decoding properlyChris McDonough2012-01-261-7/+4
|
* make bytesrequest work on python 3Chris McDonough2012-01-261-58/+98
|
* First cut at distinct TextRequest/BytesRequest implementations as aChris McDonough2012-01-251-87/+151
| | | | | | | | | | | | | | | | | | | | fix for issue #21. TextRequest is the default when Request or BaseRequest is imported under Python 3 for backwards compatibility. The only difference Python 3 users should see after upgrading to this: script_name and path_info will be decoded, and methods which erroneously dealt in raw environ values will now deal correctly in text. BytesRequest is the default when Request or BaseRequest is imported under Python 2 for backwards compatibility. It works just like the old BaseRequest under Python 2. Under Python 2, environ values are still dealt with as bytes by all methods. Under Python 3, it coerces all environ values to bytes. It's doubtful anyone will use this under Python 3. Either BytesRequest or TextRequest are usable directly under Python 2 or Python 3, but the intent is to transition people over time to TextRequest on both. Certainly new frameworks could start off using TextRequest.
* add warning to docstring of client_addr (closes #20)Chris McDonough2012-01-061-0/+10
|
* fix https://github.com/Pylons/webob/issues/18 (non-ascii form POST, then ↵Sergey Schetinin2011-12-261-4/+7
| | | | parse, then serialize)
* * Added ``request.client_addr`` API (returns IP address implied byChris McDonough2011-10-281-0/+20
| | | | HTTP_X_FORWARDED_FOR, falling back to REMOTE_ADDR).
* * Added ``request.host_port`` API (returns port number implied by HTTP_HOST,Chris McDonough2011-10-281-0/+27
| | | | falling back to SERVER_PORT).
* be less aggressive about feature removal for benefit of pylons 1.XChris McDonough2011-10-131-12/+28
|
* * Mutating the ``request.cookies`` property now reflects the mutations intofeature.cookie-bug-for-bugChris McDonough2011-10-101-11/+8
| | | | the ``HTTP_COOKIES`` environ header.
* Merge branch 'master' into feature.cookie-bug-for-bugChris McDonough2011-10-081-4/+11
|\
| * typoChris McDonough2011-10-081-1/+1
| |
| * improve deprecation warningsChris McDonough2011-10-081-4/+11
| |
* | Merge branch 'master' into feature.cookie-bug-for-bugChris McDonough2011-10-071-14/+7
|\ \ | |/
| * * Undeprecated ``uscript_name`` and ``upath_info``.Chris McDonough2011-10-061-14/+7
| | | | | | | | | | | | | | * For backwards compatibility purposes, switch ``req.script_name`` and ``path_info`` back again to contain "raw" undecoded native strings rather than text. Use ``uscript_name`` and ``upath_info`` to get the text version of SCRIPT_NAME and PATH_INFO.
| * get docstring descriptions right for cookies and paramsChris McDonough2011-10-061-2/+3
| |
* | * Mutating the ``request.cookies`` property now retains the mutated valueChris McDonough2011-10-061-5/+11
|/ | | | | during the course of a single request (bug-for-bug compatibility with previous versions; in-the-wild codebases depend upon this behavior).
* add req.json_body (adapted from Pyramid)Sergey Schetinin2011-09-301-1/+5
|
* * ``request.cookies`` property now returns an immutable dictionary;Chris McDonough2011-09-291-2/+2
| | | | attempting to modify it will result in a TypeError.
* test coverage back at 100%Sergey Schetinin2011-09-251-2/+2
|
* test coverage; transcode fixes; remove multidict_from_bodyfileSergey Schetinin2011-09-251-20/+23
|
* Merge branch 'sergey-1.2-py2-only' into 1.2-mergeSergey Schetinin2011-09-251-166/+223
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: tests/test_descriptors.py tests/test_etag.py tests/test_misc.py tests/test_multidict.py tests/test_request.py tests/test_request_nose.py tox.ini webob/cookies.py webob/dec.py webob/descriptors.py webob/etag.py webob/exc.py webob/multidict.py webob/request.py webob/response.py
| * merge transcode into requestSergey Schetinin2011-09-221-2/+72
| | | | | | | | * req = req.decode()
| * improve req.charset handlingSergey Schetinin2011-09-221-31/+47
| | | | | | | | | | | | | | | | | | * allow creating request with non-utf-8 charset in content-type * actually detect charset for req.charset * when setting allow noop assigns * check charset in POST * allow GET to work with any charset * add _content_type_raw attr
| * enable weak matching for if-none-matchSergey Schetinin2011-09-211-1/+1
| | | | | | | | | | * parse req.if_none_match with ETagMatcher.parse(val, strong=False) * full tests
| * GetDict.tracker -> on_changeSergey Schetinin2011-09-201-10/+1
| |
| * remove todo that is no longer relevantSergey Schetinin2011-09-201-1/+0
| |
| * hardcode utf-8 into FakeCGIBody and MultiDict.form_fieldstorageSergey Schetinin2011-09-201-7/+5
| |
| * hardcode Request.charset to 'UTF-8'Sergey Schetinin2011-09-201-74/+36
| | | | | | | | | | * raise errors if trying to pass non-utf8 charset to Request or to set it later, same for * remove unicode_errors, raise errors if passed into constructor
| * add webob.transcodeSergey Schetinin2011-09-201-15/+19
| | | | | | | | | | | | * new detect_charset func * _encode_multipart now assumes utf8 and can write to caller-supplied file object * some tests
| * change req.cookies implementation to parse on demandSergey Schetinin2011-09-201-15/+3
| | | | | | | | | | | | * add webob.cookies.parse_cookie for simple parsing * change _valid_cookie_name implementation to filter out $key and reserved names * do not cache parsed cookies dict in the environ
| * drop UnicodeMultiDict; change TrackableMultiDict -> GetDictSergey Schetinin2011-09-201-31/+48
| | | | | | | | | | | | * decode cgi.FieldStorage in MultiDict.from_fieldstorage * add encoding and errors params to FakeCGIBody * same for _encode_multipart
| * req.script_name and .path_info contain unicode nowSergey Schetinin2011-09-201-5/+15
| | | | | | | | | | * uscript_name and upath_info are deprecated * change deprecated_property implementation
| * refactor IfRangeSergey Schetinin2011-09-201-2/+2
| | | | | | | | | | | | * remove NoIfRange * separate IfRangeDate class * simpler __str__ and __repr__
| * remove what remains of py25 supportSergey Schetinin2011-09-201-6/+1
| |
| * deprecate more stuffSergey Schetinin2011-09-181-114/+40
| | | | | | | | | | | | | | | | | | * WARNING! doctests are broken * finalize deprecation of Request.str_* * finalize deprecation of first_match and weak_match * raise error when decode_param_names is used in any way * raise error when accessing HTTPException.exception * hardcode key decoding in UnicodeMultiDict
* | remove exec_, change reraise to take single argumentSergey Schetinin2011-09-251-1/+1
| |
* | replace iteritems_(kw) with kw.items()Sergey Schetinin2011-09-251-5/+3
| |
* | make path_info, script_name unicode, deprecate u*Sergey Schetinin2011-09-241-5/+14
| |
* | _empty_byte -> b''Sergey Schetinin2011-09-241-9/+7
| |