Issue #3162
closedPulp failed to parse updateinfo.xml file it generated
Description
We had an issue where a reference in an updateinfo.xml file didn't have an href attribute:
<reference type="other" id="ref_0" title="other_reference_0" />
Pulp simply threw an "Importer indicated a failed response" error and wasn't able to sync the repository. The backtrace wasn't particularly helpful either ( File "/usr/lib/python2.7/site-packages/pulp_rpm/plugins/importers/yum/repomd/updateinfo.py", line 88, in _parse_reference
).
'href': element.attrib['href'],
KeyError: 'href'
First, per https://bugzilla.redhat.com/show_bug.cgi?id=1503916, it seems that Pulp is generating these updateinfo.xml files that it can't consume. We should consider either rejecting errata that are invalid and missing attributes.
Second, we probably need better logging. Particularly, it would be helpful to know where in the parsed file our code is choking. It took us a couple hours to figure out the particular erratum in this case that caused the problem.
Related BZs: