This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author v+python
Recipients amaury.forgeotdarc, barry, eric.araujo, erob, flox, ggenellina, oopos, pebbe, pitrou, quentel, r.david.murray, tcourbon, tobias, v+python, vstinner
Date 2011-01-12.18:49:58
SpamBayes Score 4.3679044e-10
Marked as misclassified No
Message-id <1294858205.48.0.997751298252.issue4953@psf.upfronthosting.co.za>
In-reply-to
Content
I'd be willing to propose such a patch and tests, but I haven't a clue how, other than starting by reading the contributor document... I was putting off learning the process until hg conversion, not wanting to learn an old process for a few months :(  And I've never written an official Python test, or learned how to use the test modules, etc.  So that's a pretty steep curve for the 2 days remaining.

Due to the way that browsers actually work, vs. how the standards are written, it seems necessary to add the optional  stream_encoding parameter.  The limit parameter Pierre is proposing is also a good check against improperly formed inputs.  So there are new, optional parameters to the FieldStorage constructor.

Without these fixes, though, cgi.py continues to be totally useless for file uploads, so not releasing this in 3.2 makes 3.2 continue to be useless as a basis for web applications.  I have no idea if there is a timeframe for 3.3, nor what it is.  I'm not sure if, or how many, web frameworks use cgi.py vs. replacing the functionality.  Seems at least some replace it, so they may not suffer in porting to 3.x (except internally, grappling with the same issues).

Happily, Pierre's latest patch needs only one more fix, per my (non-Python-standard) testing.  Between his testing in one environment using default code pages, and mine using UTF-8, the bases seem to be pretty well covered for testing... certainly more than the previous default tests.  I think you contributed some tests, I haven't tried them, but it seems Pierre has, as he has a patch for that also (which I haven't tried).
History
Date User Action Args
2011-01-12 18:50:05v+pythonsetrecipients: + v+python, barry, amaury.forgeotdarc, ggenellina, pitrou, vstinner, eric.araujo, r.david.murray, oopos, tcourbon, tobias, flox, pebbe, quentel, erob
2011-01-12 18:50:05v+pythonsetmessageid: <1294858205.48.0.997751298252.issue4953@psf.upfronthosting.co.za>
2011-01-12 18:49:58v+pythonlinkissue4953 messages
2011-01-12 18:49:58v+pythoncreate