[Python-3000] move parse_header from cgi to email.header?
Bill Janssen
janssen at parc.com
Wed Aug 20 02:57:30 CEST 2008
There's a function in the cgi module called "parse_header", which
takes a MIME-style email header and returns the "main" value along
with a dictionary of the parameters in the header. I had to look for
a while before I found it; first I thought it should be in httplib,
then when it wasn't there I figured it would be in the email package,
along with the rest of the MIME support. I was surprised to finally
find it in cgi. Perhaps it should be moved to email.header,
email.parser, or email.util? (With, of course, appropriate imports
and eventually deprecations in the cgi module, which already imports
email.parser.)
And what about parse_multipart?
http://bugs.python.org/issue3609
Bill
More information about the Python-3000
mailing list