mirror of
https://github.com/openSUSE/osc.git
synced 2024-12-27 02:16:12 +01:00
Do not use the deprecated Element.getchildren anymore
Element.getchildren is deprecated and not available on python39 anymore. Instead, iterate over the element itself (which iterates over the element's children). Fixes: #903 ("AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'getchildren'")
This commit is contained in:
parent
52aa999529
commit
21274b6981
@ -7139,7 +7139,7 @@ def stripETxml(node):
|
||||
node.tail = None
|
||||
if node.text != None:
|
||||
node.text = node.text.replace(" ", "").replace("\n", "")
|
||||
for child in node.getchildren():
|
||||
for child in node:
|
||||
stripETxml(child)
|
||||
|
||||
def addGitSource(url):
|
||||
|
Loading…
Reference in New Issue
Block a user