Package: python-dogtail
Version: 0.6.1-3
Severity: important

When some applications are present (eg. iceweasel or gnome-help), one can
see the following behaviour, which seems to show a problem in the way
findChildren() walks down the Node tree:

>>> from dogtail.tree import root, predicate
Creating logfile at /tmp/dogtail/logs/log_20080611-103008_debug ...
Detecting distribution: Debian (or derived distribution)
>>> root.findChildren(predicate.GenericPredicate(roleName='application'))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 892, in
findChildren
    childList = child.findChildren(pred, recursive)
  File "/var/lib/python-support/python2.5/dogtail/tree.py", line 889, in
findChildren
    for child in children:
TypeError: 'NoneType' object is not iterable


OTOH, in this very case there is a workaround, and dogtail should be able
to work with those apps that don'k break its expectations:

>>> root.findChildren(predicate.GenericPredicate(roleName='application'),recursive=False)
[<dogtail.tree.Node instance at 0x854c78c>, <dogtail.tree.Node instance at
0x854c7ec>]





--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to