diff -r 0238cc842805 Lib/idlelib/CallTips.py --- a/Lib/idlelib/CallTips.py Thu Dec 06 17:49:58 2012 -0500 +++ b/Lib/idlelib/CallTips.py Thu Dec 06 19:36:57 2012 -0600 @@ -100,7 +100,11 @@ return rpcclt.remotecall("exec", "get_the_calltip", (expression,), {}) else: - return get_argspec(get_entity(expression)) + try: + tip = get_argspec(get_entity(expression)) + except Exception as err: + tip = 'Error while retrieving call tip: %r' % err + return tip def get_entity(expression): """Return the object corresponding to expression evaluated @@ -185,6 +189,8 @@ @staticmethod def sm(b): "(b)" def __call__(self, ci): "(self, ci)" + def __getattr__(self, name): + raise Exeception('') tc = TC() @@ -244,6 +250,7 @@ (TC.cm, "(a)"),): test('tc.'+meth.__name__, mdoc + "\n" + meth.__doc__) test('tc', "(ci)" + "\n" + tc.__call__.__doc__) + test('tc.break', '') # .break causes raised exception # directly test that re works to delete unicode parameter name uni = "(A\u0391\u0410\u05d0\u0627\u0905\u1e00\u3042, a)" # various As assert _first_param.sub('', uni) == '(a)'