How to clone Element objects in Python xml.etree? I\'m trying to procedurally move and copy (then modify their attributes) nodes.
Element
xml.etree
A different, and somewhat disturbing solution:
new_element = lxml.etree.fromstring(lxml.etree.tostring(elem))