[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XEN PATCH 8/9] CI: Workaround extra content in junit



On Tue, 3 Jun 2025, Anthony PERARD wrote:
> On Tue, Jun 03, 2025 at 03:12:32PM +0100, Andrew Cooper wrote:
> > On 03/06/2025 1:42 pm, Anthony PERARD wrote:
> > >  if [ -n "$retrieve_xml" ]; then
> > >      nc -w 10 "$SUT_ADDR" 8080 > tests-junit.xml </dev/null
> > > +    # Workaround duplicated data been received
> > > +    sed -i.old '/^<\/testsuites>/q' tests-junit.xml > /dev/null
> > > +    extra_line_in_junit=$(($(wc -l < tests-junit.xml.old) - $(wc -l < 
> > > tests-junit.xml)))
> > > +    if [ $extra_line_in_junit -gt 0 ]; then
> > > +        echo "WARNING: Found $extra_line_in_junit too many lines in 
> > > junit."
> > > +    fi
> > 
> > Is this the cause of
> > https://gitlab.com/xen-project/hardware/xen-staging/-/pipelines/1849342222/test_report
> > getting a row of 0's for ADL ?
> 
> Well, the error I had was this one:
> "FATAL: Extra content at the end of the document"
> https://gitlab.com/xen-project/hardware/xen-staging/-/pipelines/1848598740/test_report
> 
> And indeed, when I managed to dl the junit.xml, there were the end of
> the document duplicated many times.

Wouldn't it better to do |sort|uniq to dedup the file?



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.