Message161742
'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): return 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:44 | terry.reedy | set | recipients: + terry.reedy, ned.deily, roger.serwy, Roy.Fox | | 2012-05-28 00:10:44 | terry.reedy | set | messageid: <1338163844.86.0.670250062584.issue12510@psf.upfronthosting.co.za> | | 2012-05-28 00:10:44 | terry.reedy | link | issue12510 messages | | 2012-05-28 00:10:44 | terry.reedy | create | | |