[Python-checkins] peps: Make the relationship between 409 and 415 clearer

nick.coghlan python-checkins at python.org
Tue May 15 13:53:36 CEST 2012


http://hg.python.org/peps/rev/630a00e4f19b
changeset:   4378:630a00e4f19b
user:        Nick Coghlan <ncoghlan at gmail.com>
date:        Tue May 15 21:53:25 2012 +1000
summary:
  Make the relationship between 409 and 415 clearer

files:
  pep-0409.txt |   5 +++++
  pep-0415.txt |  11 +++++++----
  2 files changed, 12 insertions(+), 4 deletions(-)


diff --git a/pep-0409.txt b/pep-0409.txt
--- a/pep-0409.txt
+++ b/pep-0409.txt
@@ -8,6 +8,7 @@
 Content-Type: text/x-rst
 Created: 26-Jan-2012
 Post-History: 30-Aug-2002, 01-Feb-2012, 03-Feb-2012
+Superseded-By: 415
 Resolution: http://mail.python.org/pipermail/python-dev/2012-February/116136.html
 
 
@@ -87,6 +88,10 @@
 Implementation Discussion
 =========================
 
+Note: after acceptance of this PEP, a cleaner implementation mechanism
+was proposed and accepted in PEP 415. Refer to that PEP for more
+details on the implementation actually used in Python 3.3.
+
 Currently, ``None`` is the default for both ``__context__`` and ``__cause__``.
 In order to support ``raise ... from None`` (which would set ``__cause__`` to
 ``None``) we need a different default value for ``__cause__``.  Several ideas
diff --git a/pep-0415.txt b/pep-0415.txt
--- a/pep-0415.txt
+++ b/pep-0415.txt
@@ -10,16 +10,19 @@
 Created: 26-Feb-2012
 Python-Version: 3.3
 Post-History: 26-Feb-2012
+Replaces: 409
 Resolution: http://mail.python.org/pipermail/python-dev/2012-May/119467.html
 
 
 Abstract
 ========
 
-PEP 409 allows PEP 3134 exception contexts and causes to be suppressed when the
-exception is printed. This is done using the ``raise exc from None``
-syntax. This PEP proposes to implement context and cause suppression
-differently.
+PEP 409 introduced support for the ``raise exc from None`` construct to
+allow the display of the exception context to be explicitly suppressed.
+This PEP retains the language level changes already implemented in PEP 409,
+but replaces the underlying implementation mechanism with a simpler approach
+based on a new ``__suppress_context__`` attribute on all ``BaseException``
+instances.
 
 
 PEP Acceptance

-- 
Repository URL: http://hg.python.org/peps


More information about the Python-checkins mailing list