accept: Catch requests without description

Fixes #2799
This commit is contained in:
Stephan Kulow 2022-04-08 08:06:17 +02:00
parent bd0bc3062e
commit de6a64c464

View File

@ -68,9 +68,10 @@ class AcceptCommand(object):
f = http_GET(url) f = http_GET(url)
root = ET.parse(f).getroot() root = ET.parse(f).getroot()
description = root.find('description').text description = root.find('description')
if not description: if description is None or description.text is None:
return return
description = description.text
for line in description.splitlines(): for line in description.splitlines():
# this relies on the format relied upon in check_bugowner # this relies on the format relied upon in check_bugowner
m = re.search(r'^bugowner:\s*(\S*)', line) m = re.search(r'^bugowner:\s*(\S*)', line)