So I asked a few questions in #python, and there seemed to be some
disagreement with trying to support 2.5-3.2 all in one code base
without the use of 2to3 and 3to2.  I wanted to know how you felt about
it.  Some of their main points were that it makes the code quite messy
for both versions, and a lot of dirty hacks have to be used to support
all the way back to 2.5.  Here is most of the discussion
http://pastebin.com/Y5QPJukD.  Supporting Python 2 and 3 through code
generation is a lot easier than I think you believe, you can extend
lib2to3 to do pretty much everything you need, and distribute can run
2to3 or 3to2 on a system to make sure it gets the correct version of
the codebase.  Just check it out, b/c I do feel like I am really
making changes that will have to ine day be deciphered again to fit
Python 3 fully, which includes buying into Py3's way of doing things.

On Wed, Jun 22, 2011 at 6:43 PM, Chris McDonough <[email protected]> wrote:
> The second alpha of Pyramid 1.1 (1.1a2) has been released.
>
> Here are the changes:
>
> Bug Fixes
> ---------
>
> - 1.1a1 broke Akhet by not providing a backwards compatibility import
>  shim for ``pyramid.paster.PyramidTemplate``.  Now one has been
>  added, although a deprecation warning is emitted when Akhet imports
>  it.
>
> - If multiple specs were provided in a single call to
>  ``config.add_translation_dirs``, the directories were inserted into
>  the beginning of the directory list in the wrong order: they were
>  inserted in the reverse of the order they were provided in the
>  ``*specs`` list (items later in the list were added before ones
>  earlier in the list).  This is now fixed.
>
> Backwards Incompatibilities
> ---------------------------
>
> - The pyramid Router attempted to set a value into the key
>  ``environ['repoze.bfg.message']`` when it caught a view-related
>  exception for backwards compatibility with applications written for
>  ``repoze.bfg`` during error handling.  It did this by using code
>  that looked like so::
>
>                    # "why" is an exception object
>                    try:
>                        msg = why[0]
>                    except:
>                        msg = ''
>
>                    environ['repoze.bfg.message'] = msg
>
>  Use of the value ``environ['repoze.bfg.message']`` was
>  docs-deprecated in Pyramid 1.0.  Our standing policy is to not
>  remove features after a deprecation for two full major releases, so
>  this code was originally slated to be removed in Pyramid 1.2.
>  However, computing the ``repoze.bfg.message`` value was the source
>  of at least one bug found in the wild
>  (https://github.com/Pylons/pyramid/issues/199), and there isn't a
>  foolproof way to both preserve backwards compatibility and to fix
>  the bug.  Therefore, the code which sets the value has been removed
>  in this release.  Code in exception views which relies on this
>  value's presence in the environment should now use the ``exception``
>  attribute of the request (e.g. ``request.exception[0]``) to retrieve
>  the message instead of relying on
>  ``request.environ['repoze.bfg.message']``.
>
>
> A "What's New In Pyramid 1.1" document exists at
> http://docs.pylonsproject.org/projects/pyramid/1.1/whatsnew-1.1.html .
>
> You will be able to see the 1.1 release documentation (across all
> alphas and betas, as well as when it eventually gets to final release)
> at http://docs.pylonsproject.org/projects/pyramid/1.1/ .
>
> You can install it via PyPI:
>
>  easy_install Pyramid==1.1a2
>
> Enjoy, and please report any issues you find to the issue tracker at
> https://github.com/Pylons/pyramid/issues
>
> Thanks!
>
> - C
>
>
> --
> You received this message because you are subscribed to the Google Groups 
> "pylons-discuss" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/pylons-discuss?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en.

Reply via email to