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.

Author terry.reedy
Recipients Roy.Fox, ned.deily, roger.serwy, terry.reedy
Date 2012-05-28.00:10:44
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
'a'(, [](, {}( no longer do anything.
[int][0]( and {0:int}[0] bring up int tooltip.

However, patch is not a complete fix yet.
[int][1]( and {0:int}[1] both 'crash' Idle.
So we need to add IndexError and KeyError to
+            except (NameError, AttributeError, SyntaxError):

I think instead we should just remove the list since any uncaught error in the eval will close Idle. Do you see any reason why not? If open_calltips were called with evalfuncs True (I presume there must be a way, see below), then *any* exception could happen in the eval.

I was thinking that eval is a bit dangerous but I see this protection in open_calltips"

        if not evalfuncs and (name.find('(') != -1):

Consequently, after "def f(): return int", f()( does not get a calltip. Neither does the tuple equivalent of the list example above, (int,)[0](.

With the call check moved from the bottom of get_argspec to the top, I am ok with it there. If we agree on the except clause, I am ready to apply.
Date User Action Args
2012-05-28 00:10:44terry.reedysetrecipients: + terry.reedy, ned.deily, roger.serwy, Roy.Fox
2012-05-28 00:10:44terry.reedysetmessageid: <>
2012-05-28 00:10:44terry.reedylinkissue12510 messages
2012-05-28 00:10:44terry.reedycreate