Created on 2011-03-25 08:42 by gwideman, last changed 2022-04-11 14:57 by admin. This issue is now closed.
Messages (7) |
|
|
msg132072 - (view) |
Author: Graham Wideman (gwideman) |
Date: 2011-03-25 08:42 |
In Language Ref section 7 "Compound Statements": http://docs.python.org/release/3.1.3/reference/compound_stmts.html there's a footnote regarding what happens to unhandled exceptions in a try-except statement: [1] The exception is propagated to the invocation stack only if there is no *finally* clause that negates the exception. This is very unclearly worded, especially since the reader in need of this footnote is probably familiar with the *except* clause being the one to "negate" an exception, and may well think this footnote is in error. This footnote could provide a more convincing explanation: [1] The exception is propagated to the invocation stack unless there is a finally clause which happens to raise another exception. That new exception causes the old exception to be lost. |
|
|
msg137816 - (view) |
Author: Petri Lehtinen (petri.lehtinen) *  |
Date: 2011-06-07 11:58 |
Keywords suggest that there should to be a patch here. Where is it? |
|
|
msg138262 - (view) |
Author: R. David Murray (r.david.murray) *  |
Date: 2011-06-13 16:27 |
Sometimes we use the patch keyword for doc issues where someone has suggested a specific new wording but not generated an actual patch. That seems to be the case here. |
|
|
msg139092 - (view) |
Author: Sandro Tosi (sandro.tosi) *  |
Date: 2011-06-25 16:05 |
Just to make explicit what's happening: >>> try: ... try: ... raise TypeError() ... finally: ... raise ValueError() ... except TypeError as e: ... print('mmm') ... Traceback (most recent call last): File "", line 3, in TypeError During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 5, in ValueError while >>> try: ... try: ... raise TypeError() ... finally: ... raise ValueError() ... except ValueError as e: ... print ('mmm') ... mmm |
|
|
msg139093 - (view) |
Author: Sandro Tosi (sandro.tosi) *  |
Date: 2011-06-25 16:05 |
Ok, I send it too soon... attached is a patch to fix this bug (it applies on default, 3.2 and 2.7). |
|
|
msg139152 - (view) |
Author: Roundup Robot (python-dev)  |
Date: 2011-06-26 08:38 |
New changeset b11e7bc76d07 by Ezio Melotti in branch '2.7': #11669: rephrase footnote in the Compound Statements page. http://hg.python.org/cpython/rev/b11e7bc76d07 New changeset 74e9f94d8440 by Ezio Melotti in branch '3.2': #11669: rephrase footnote in the Compound Statements page. http://hg.python.org/cpython/rev/74e9f94d8440 New changeset a7099a3b5e5f by Ezio Melotti in branch 'default': #11669: merge with 3.2. http://hg.python.org/cpython/rev/a7099a3b5e5f |
|
|
msg139153 - (view) |
Author: Ezio Melotti (ezio.melotti) *  |
Date: 2011-06-26 08:41 |
Fixed, thanks for the patch! |
|
|
History |
|
|
|
Date |
User |
Action |
Args |
2022-04-11 14:57:15 |
admin |
set |
github: 55878 |
2011-07-21 09:33:42 |
ezio.melotti |
set |
nosy: + ncoghlan |
2011-06-26 08:41:23 |
ezio.melotti |
set |
status: open -> closedassignee: docs@python -> ezio.melottinosy: + ezio.melottimessages: + resolution: fixedstage: patch review -> resolved |
2011-06-26 08:38:38 |
python-dev |
set |
nosy: + python-devmessages: + |
2011-06-25 16:06:18 |
sandro.tosi |
set |
keywords: - needs reviewfiles: + issue11669-default.patch |
2011-06-25 16:05:53 |
sandro.tosi |
set |
messages: + |
2011-06-25 16:05:24 |
sandro.tosi |
set |
nosy: + sandro.tosimessages: + |
2011-06-13 16:28:07 |
r.david.murray |
set |
versions: - Python 3.1 |
2011-06-13 16:27:16 |
r.david.murray |
set |
nosy: + r.david.murraymessages: + |
2011-06-07 11:58:54 |
petri.lehtinen |
set |
nosy: + petri.lehtinenmessages: + |
2011-03-25 16:10:34 |
eric.araujo |
set |
keywords: + patch, needs reviewstage: patch reviewversions: - Python 2.6, Python 2.5, Python 3.4 |
2011-03-25 08:42:54 |
gwideman |
create |
|