Commits

Anonymous committed 04becd0

Changed page WhatsNewIn32

Comments (0)

Files changed (1)

WhatsNewIn32.wiki

 
 !CherryPy 3.2 runs on Python 3! You'll find separate downloadable packages, as well as a separate Subversion branch. Python 2.6 support has been improved, too, by the way.
 
+The biggest change required for Python 3 is the switch from bytes to unicode. CherryPy 3.1 only ran on Python 2, and used WSGI 1.0, all of which favored byte strings over unicode strings. But in Python 3, unicode strings are preferred; this has quickly led to the adoption of WSGI 1.1, which uses unicode strings for its `environ` dict instead of byte strings. CherryPy 3.2 for ''both'' Python 2 and 3 will support ''both'' WSGI 1.0 and 1.1; there's a new `server.wsgi_version` configuration option to inform the `wsgiserver` which version to emit, and the application side reads the WSGI environ according to the 'wsgi.version' entry.
+
+This is complicated enough to need a handy chart:
+
+||                || '''Default WSGI''' || '''`request` attributes; handler args''' ||
+|| CP 3.2 for py2 ||             (1, 0) ||                       bytes (type <str>) ||
+|| CP 3.2 for py3 ||             (1, 1) ||                     unicode (type <str>) ||
+
+
 == Deployment ==
 
 === FastCGI/SCGI ===
 
 == Request Bodies ==
 
-CherryPy 3.2 has a new `_cpreqbody` module which completely replaces its use of the standard library's `cgi` module (and our `safemime` and `cpcgifs` modules, to boot). There are default processors for common content-types (including improved support for `multipart/*` types), and allows you to write your own custom processors!
+CherryPy 3.2 has a new `_cpreqbody` module which completely replaces its use of the standard library's `cgi` module (and our `safemime` and `cpcgifs` modules, to boot). There are default processors for common content-types (including improved support for `multipart/*` types), and allows you to write your own custom processors! See RequestBodies for more details.
 
 == Configuration ==