question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Illegal XML characters output in checkstyle format

See original GitHub issue

Jenkins checkstyle complains that character reference “&#26” is an invalid XML character. Online XML validator http://www.xmlvalidation.com/index.php?id=1&L=0 confirms.

<error line="1" column="1" severity="error" message="Parsing error: Unexpected character &apos;&#65533;&apos;&#10;&#10;&gt; 1 | &#65533;PNG&#10;    | ^&#10;  2 | &#26;&#10;  3 | &#0;&#0;&#0;&#10;  4 | IHDR&#0;&#0;&#0;F&#0;&#0;&#0;F&#8;&#6;&#0;&#0;&#0;q.&#65533;&#65533;&#0;&#0;&#0;&#4;gAMA&#0;&#0;&#65533;&#65533;&#11;&#65533;a&#5;&#0;&#0;&#0;&#9;pHYs&#0;&#0;&#14;&#65533;&#0;&#0;&#14;&#65533;&#1;&#65533;&#65533;k&#65533;&#0;&#0;&#0;&#25;tEXtSoftware&#0;Paint.NET v3.5.5I&#65533;&#65533;&#65533;&#0;&#0;" source="" /></file>

Environment

  • ESLint Version: 3.12.0
  • Node Version: 6.9.1
  • npm Version: 4.0.2
  • OS Version: Windows 10 x64

Using parser babel-eslint

{ “extends”: “airbnb”, “parser”: “babel-eslint” }

On executiong: "node ./node_modules/eslint/bin/eslint.js -f checkstyle -o lint-report.xml src/**/*

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:19 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
BWJesseRcommented, Dec 20, 2016

Oh, forgot to respond to @platinumazure, using the -o option and not using Ant’s output results in the same issue. The invalid characters are from it trying to convert the garbage characters in the image to XML.

@not-an-aardvark thanks for that clarification. That explains the issue. 👍

0reactions
not-an-aardvarkcommented, Dec 26, 2016

It looks like the conclusion was that this is not a bug in ESLint, so I’m going to close this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

What are invalid characters in XML - Stack Overflow
In XML 1.0 there are many illegal characters. In fact even using a character entity for most control characters will cause an error...
Read more >
checkstyle – Configuration - SourceForge
Checkstyle obtains a configuration from an XML document whose elements specify the configuration's hierarchy of modules and their properties. ...
Read more >
Miscellaneous - checkstyle
Checks the style of array type definitions. Some like Java style: public static void main(String[] args) and some like C style: public ...
Read more >
Command Line - checkstyle
-f format - Specifies the output format. Valid values: xml , sarif , plain for XMLLogger, SarifLogger, and DefaultLogger respectively.
Read more >
Regexp - checkstyle
<module name="Regexp"> <property name="format" value="// This code is ... otherwise it will think they are special instruction characters.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found