Fix URL normalization for MultiDict objects with duplicate keys
E.g., so http://url.com?foo=bar&foo=baz is cached separately from http://url.com?foo=bar
Update ignored_params to also apply to headers (if include_headers=True)
As a bonus, I saw that yarl.URL.with_query() conveniently does the work of parsing/modifying/unparsing query strings, so I was able to use that instead of the more verbose urllib.parse.urlparse/parse_qsl/urlunparse.
Fixes #105. Other improvements:
MultiDict
objects with duplicate keyshttp://url.com?foo=bar&foo=baz
is cached separately fromhttp://url.com?foo=bar
ignored_params
to also apply to headers (ifinclude_headers=True
)As a bonus, I saw that
yarl.URL.with_query()
conveniently does the work of parsing/modifying/unparsing query strings, so I was able to use that instead of the more verboseurllib.parse.urlparse
/parse_qsl
/urlunparse
.