New submission from Pierre Quentel:

In the cgi module, the parse_multipart() function duplicates code from 
FieldStorage, and the result is not compliant with that of FieldStorage for 
requests sent with multipart/form-data : for non-file fields, the value 
associated with a key is a list of *bytes* in parse_multipart() and a list of 
*strings* for FieldStorage (the bytes decoded with the argument "encoding" 
passed to FieldStorage()).

I will propose a PR on the Github repo with a version of parse_multipart that 
uses FieldStorage and returns the same result (values as strings). The function 
will take an additional argument "encoding".

----------
components: Library (Lib)
messages: 291117
nosy: quentel
priority: normal
severity: normal
status: open
title: cgi.parse_multipart is not consistent with FieldStorage
type: behavior
versions: Python 3.7

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue29979>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to