This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2010年02月04日 09:35 by flox, last changed 2022年04月11日 14:56 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| case_contextmanager_exit.py | flox, 2010年02月04日 09:37 | |||
| issue7853_cm_exit.diff | flox, 2010年02月05日 00:40 | Patch, apply to trunk | ||
| Messages (7) | |||
|---|---|---|---|
| msg98817 - (view) | Author: Florent Xicluna (flox) * (Python committer) | Date: 2010年02月04日 09:35 | |
On __exit__(), the 3rd argument "exc_value" should contain the instance of the exception. But in most cases, it contains only the string representation of the exception. See attached test case. Same behavior for KeyError, AttributeError, RuntimeError, ... |
|||
| msg98833 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2010年02月04日 12:47 | |
Indeed, it seems the exception isn't always normalized. |
|||
| msg98834 - (view) | Author: Benjamin Peterson (benjamin.peterson) * (Python committer) | Date: 2010年02月04日 12:48 | |
Has this behavior changed between 2.6 and 2.7? |
|||
| msg98835 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2010年02月04日 12:52 | |
No, it's also in 2.6. |
|||
| msg98860 - (view) | Author: Florent Xicluna (flox) * (Python committer) | Date: 2010年02月05日 00:40 | |
Patch. |
|||
| msg98863 - (view) | Author: Benjamin Peterson (benjamin.peterson) * (Python committer) | Date: 2010年02月05日 02:12 | |
Fixed in r77983. |
|||
| msg98928 - (view) | Author: Benjamin Peterson (benjamin.peterson) * (Python committer) | Date: 2010年02月06日 02:03 | |
BTW, I'm not going to backport this fix, since the implementation does carry over well to 2.6. Additionally, it is probably an unacceptable change of behavior in a bug fix release. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:57 | admin | set | github: 52101 |
| 2010年02月06日 02:03:18 | benjamin.peterson | set | messages: + msg98928 |
| 2010年02月05日 02:12:53 | benjamin.peterson | set | status: open -> closed resolution: fixed messages: + msg98863 |
| 2010年02月05日 00:40:14 | flox | set | files:
+ issue7853_cm_exit.diff keywords: + patch messages: + msg98860 stage: test needed -> patch review |
| 2010年02月04日 21:24:57 | benjamin.peterson | set | assignee: benjamin.peterson |
| 2010年02月04日 12:52:28 | pitrou | set | messages: + msg98835 |
| 2010年02月04日 12:48:51 | benjamin.peterson | set | messages: + msg98834 |
| 2010年02月04日 12:47:07 | pitrou | set | nosy:
+ pitrou, benjamin.peterson messages: + msg98833 |
| 2010年02月04日 09:37:57 | flox | set | files: + case_contextmanager_exit.py |
| 2010年02月04日 09:37:49 | flox | set | files: - case_contextmanager_exit.py |
| 2010年02月04日 09:35:08 | flox | create | |