Commit 97bf4ad0 authored by Andrii Salnikov's avatar Andrii Salnikov

replace iter with findall for XML parsing in arcctl deploy voms to work with python2.6

parent 3e43c944
......@@ -63,7 +63,7 @@ class ThirdPartyControl(ComponentControl):
vomslsc = {}
xml = self.__egi_get_voms_xml(vo)
# parse XML
for voms in xml.iter('VOMS_Server'):
for voms in xml.findall('.//VOMS_Server'):
host = voms.find('hostname').text
dn = voms.find('X509Cert/DN').text
ca = voms.find('X509Cert/CA_DN').text
......@@ -73,7 +73,7 @@ class ThirdPartyControl(ComponentControl):
def __egi_get_vomses(self, vo):
vomses = []
xml = self.__egi_get_voms_xml(vo)
for voms in xml.iter('VOMS_Server'):
for voms in xml.findall('.//VOMS_Server'):
port = None
if 'VomsesPort' in voms.attrib:
port = voms.attrib['VomsesPort']
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment