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 roger.serwy
Recipients roger.serwy, terry.reedy
Date 2012-12-07.01:46:14
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
The calltip fails if __getattr__ raises an exception. Take as an example:

Python 3.4.0a0 (default:0238cc842805+, Dec  6 2012, 19:17:04) 
[GCC 4.7.2] on linux
Type "copyright", "credits" or "license()" for more information.
>>> class Test:
	def __getattr__(self, name):
		raise Exception()

>>> a = Test()
>>> a(

This traceback is sent to stderr:

Exception in Tkinter callback
Traceback (most recent call last):
  File "/home/serwy/Code/python/cpython/Lib/tkinter/", line 1442, in __call__
    return self.func(*args)
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 166, in handler
    r = l[i](event)
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 56, in try_open_calltip_event
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 75, in open_calltip
    argspec = self.fetch_tip(expression)
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 101, in fetch_tip
    (expression,), {})
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 216, in remotecall
    return self.asyncreturn(seq)
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 247, in asyncreturn
    return self.decoderesponse(response)
  File "/home/serwy/Code/python/cpython/Lib/idlelib/", line 267, in decoderesponse
    raise what

The attached patch fixes the issue.
Date User Action Args
2012-12-07 01:46:15roger.serwysetrecipients: + roger.serwy, terry.reedy
2012-12-07 01:46:15roger.serwysetmessageid: <>
2012-12-07 01:46:15roger.serwylinkissue16630 messages
2012-12-07 01:46:14roger.serwycreate