[New-bugs-announce] [issue21654] IDLE call tips emitting future warnings about ElementTree objects

Raymond Hettinger report at bugs.python.org
Wed Jun 4 03:31:00 CEST 2014


New submission from Raymond Hettinger:

While editing code that uses ElementTree, the call tips code is working in the background and emits warnings to the console:

Warning (from warnings module):
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/idlelib/CallTips.py", line 170
    if ob.im_self:
FutureWarning: The behavior of this method will change in future versions.  Use specific 'len(elem)' or 'elem is not None' test instead.

This appears to be an unfortunate interaction between the call tips code and the objects being call-tipped.  The behavior appears to be new (I had not encountered it prior to 2.7.7).

If possible the call-tip code should test for len(ob.im_self) or somesuch.

----------
components: IDLE
messages: 219739
nosy: rhettinger
priority: normal
severity: normal
status: open
title: IDLE call tips emitting future warnings about ElementTree objects
type: behavior
versions: Python 2.7

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue21654>
_______________________________________


More information about the New-bugs-announce mailing list