Thank you Armin this makes things clear to me ( a newbie hre).

On Sep 22, 2009, at 3:29 AM, Armin Ronacher wrote:
- my initial plan was going bytes everywhere.  Turns out, on Python 3
 this is nearly impossible to do because the majority of the standard
 library went an unicode path, even where bytes would be more
 appropriate (like cgi.FieldStorage, urllib.parse etc.)

I would have taken the same stand.

- Graham, Robert (and now me as well) try to get charset guessing for
 URLs going, decide on latin1 for the HTTP headers.  latin1 could be
 re-decoded by the application if it really thinks it wanted utf-8
 for instance.  (Like cookie headers, only I guess only there)

If wsgi guesses the charset before will the application always be able to derive the original strings?

- One idea is enforcing unicode for all Python versions

- One idea is going unicode for Python 3 and bytestrings for Python 2

For what it matters I prefer the latter option.
_______________________________________________
Web-SIG mailing list
Web-SIG@python.org
Web SIG: http://www.python.org/sigs/web-sig
Unsubscribe: 
http://mail.python.org/mailman/options/web-sig/archive%40mail-archive.com

Reply via email to