Author pitrou
Recipients gvanrossum, janssen, jimjjewett, lemburg, loewis, mgiuca, orsenthil, pitrou, thomaspinckney3
Date 2008-08-10.10:49:51
SpamBayes Score 3.76854e-05
Marked as misclassified No
Message-id <1218365389.5894.15.camel@fsol>
In-reply-to <1218351947.75.0.785102512508.issue3300@psf.upfronthosting.co.za>
Content
Le dimanche 10 août 2008 à 07:05 +0000, Matt Giuca a écrit :
> I don't think it's worth the extra code bloat and performance hit just
> to implement a feature whose only use is producing invalid URIs (since
> URIs are supposed to only have ASCII characters).

Agreed.

> If the QUERY_STRING is "foo=w%FCt" (Latin-1), with errors='strict', you
> get a UnicodeDecodeError when you call cgi.FieldStorage(). With
> errors='replace', the variable foo will be "w�t". I think in general I'd
> rather have '�'s in my program (representing invalid user input) than
> exceptions, since this is usually a user input error, not a programming
> error.

Invalid user input? What if the query string comes from filling a form?
For example if I search the word "numéro" in a latin1 Web site, I get
the following URL:
http://www.le-tigre.net/spip.php?page=recherche&recherche=num%E9ro
History
Date User Action Args
2008-08-10 10:50:03pitrousetrecipients: + pitrou, lemburg, gvanrossum, loewis, jimjjewett, janssen, orsenthil, thomaspinckney3, mgiuca
2008-08-10 10:49:52pitroulinkissue3300 messages
2008-08-10 10:49:51pitroucreate