[Python-Dev] cpython (3.2): Issue12510: Attempting to get invalid tooltip no longer closes Idle.
Georg Brandl
g.brandl at gmx.net
Mon May 28 08:53:04 CEST 2012
Am 28.05.2012 03:55, schrieb terry.reedy:
> http://hg.python.org/cpython/rev/4a7582866735
> changeset: 77195:4a7582866735
> branch: 3.2
> parent: 77189:6737c2ca98ee
> user: Terry Jan Reedy <tjreedy at udel.edu>
> date: Sun May 27 21:29:17 2012 -0400
> summary:
> Issue12510: Attempting to get invalid tooltip no longer closes Idle.
> Original patch by Roger Serwy.
>
> files:
> Lib/idlelib/CallTips.py | 9 ++++++---
> Misc/NEWS | 3 +++
> 2 files changed, 9 insertions(+), 3 deletions(-)
>
>
> diff --git a/Lib/idlelib/CallTips.py b/Lib/idlelib/CallTips.py
> --- a/Lib/idlelib/CallTips.py
> +++ b/Lib/idlelib/CallTips.py
> @@ -110,7 +110,9 @@
> namespace.update(__main__.__dict__)
> try:
> return eval(name, namespace)
> - except (NameError, AttributeError):
> + # any exception is possible if evalfuncs True in open_calltip
> + # at least Syntax, Name, Attribute, Index, and Key E. if not
Is something missing here? The comment text seems cut off.
> + except:
> return None
"except Exception" may be better here.
Georg
More information about the Python-Dev
mailing list