[issue5468] urlencode does not handle "bytes", and could easily handle alternate encodings

Miles Kaufmann report at bugs.python.org
Fri Aug 28 11:38:22 CEST 2009


Miles Kaufmann <milesck at umich.edu> added the comment:

I've attached a patch that provides similar functionality to Dan Mahn's 
urlencode(), as well as providing encoding and errors parameters to 
parse_qs and parse_qsl, updating the documentation to reflect the added 
parameters, and adding test cases.  The implementation of urlencode() is 
not the same as dmahn's, and has a more straightforward control flow and 
less code duplication than the current implementation.

(For the tests, I tried to match the style of the file I was adding to 
with regard to (expect, result) order, which is why it's inconsistent.)

----------
keywords: +patch
versions: +Python 3.2
Added file: http://bugs.python.org/file14796/urllib_parse.py3k.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5468>
_______________________________________


More information about the Python-bugs-list mailing list