Stefan Behnel <stefan...@behnel.de> added the comment:
@WoodyWoo, you can (and should) do something like this: for ELEMchild in list(etroot): Modifying a container while iterating over it is usually not a good idea. The same applies to Python lists and dicts, for example. ---------- stage: patch review -> _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue41892> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com