Changelog¶
1.4.3 (30-Oct-2017)¶
- Change parsing of qualified lists to retain the initial ordering whenever
possible. The algorithm prefers explicit highest quality (1.0) preferences
over inferred highest quality preferences. It also retains the initial
ordering in the presence of multiple highest quality matches. This affects
headers.parse_accept_charset()
,headers.parse_accept_encoding()
, andheaders.parse_accept_language()
.
1.4.0 (18-Oct-2016)¶
- Fixed parsing of lists like
max-age=5, x-foo="prune"
. The previous versions incorrectly produced['max-age=5', 'x-foo="prune']
. - Added
headers.parse_accept_encoding()
which parses HTTP Accept-Encoding header values into a list. - Added
headers.parse_accept_language()
which parses HTTP Accept-Language header values into a list.
1.3.0 (11-Aug-2016)¶
- Added
headers.parse_cache_control()
which parses HTTP Cache-Control header values into a dictionary. - Renamed
headers.parse_http_accept_header()
toheaders.parse_accept()
, adding a wrapper function that raises a deprecation function when invokingheaders.parse_http_accept_header()
. - Renamed
headers.parse_link_header()
toheaders.parse_link()
, adding a wrapper function that raises a deprecation function when invokingheaders.parse_link_header()
. - Renamed
headers.parse_list_header()
toheaders.parse_list()
, adding a wrapper function that raises a deprecation function when invokingheaders.parse_list_header()
.
1.2.2 (27-May-2015)¶
- Added
headers.parse_list_header()
which parses generic comma- separated list headers with support for quoted parts. - Added
headers.parse_accept_charset()
which parses an HTTP Accept-Charset header into a sorted list.
1.2.1 (25-May-2015)¶
algorithms.select_content_type()
claims to work withdatastructures.ContentType`
values but it was requiring the augmented ones returned fromalgorithms.parse_http_accept_header()
. IOW, the algorithm required that the quality attribute exist. RFC 7231#section-5.3.1 states that missing quality values are treated as 1.0.
1.2.0 (19-Apr-2015)¶
- Added support for RFC 5988
Link
headers. This consists ofheaders.parse_link_header()
anddatastructures.LinkHeader
1.1.1 (10-Feb-2015)¶
- Removed
setupext
module since it was causing problems with source distributions.
1.1.0 (26-Oct-2014)¶
- Added
algorithms.rewrite_url()
1.0.0 (21-Sep-2014)¶
- Initial implementation containing the following functionality:
-
algorithms.select_content_type()
-datastructures.ContentType
-errors.NoMatch
-errors.RootException
-headers.parse_content_type()
-headers.parse_http_accept_header()