PMD XML report import stopped working after 9.1.3 upgrade
After upgrading to TC9.1.3 from 9.1.0, our PMD code duplicate detection task started failing with the following error:
[10:47:38][Parsing errors] Failed to parse 1 report
[10:47:38][Parsing errors] build\test\testresults\metrics\duplicates_report.xml: Report is incomplete or has unexpected structure
Prior to the upgrade, it worked fine. Tested with PMD 5.1.0 and 5.4.0. The XML file itself seems structurally sound.
Please sign in to leave a comment.
Hi Anders,
Could you please attach an example of PMD report xml file? It will help to reproduce and debug issue.
I can't attach any of our regular reports, as they contain fragments of sourcecode, but I can try to reproduce the problem with a report generated from open-source code.
Hi,
Have you been able to reproduce the issue? If not, you can use the online support form to share private information with us.
I've discovered this happening in version 8.1.4. Our source code has references to the 'SOH' character https://en.wikipedia.org/wiki/C0_and_C1_control_codes#SOH
Even though the maven-produced cpd.xml is valid xml, it seems that the TeamCity parser fails on files containing this character.
Reported as issue TW-43120.