[ http://jira.codehaus.org/browse/MJNCSS-10?page=comments#action_84923 ] 
            
Jean-Laurent de Morlhon commented on MJNCSS-10:
-----------------------------------------------

AFAIK the previous stacktrace  comment is not linked to your problem :

This one match better your bug description:
INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] An error has occurred in JavaNCSS Report report generation.

Embedded error: Invalid byte 2 of 3-byte UTF-8 sequence. Nested exception: 
Invalid byte 2 of 3-byte UTF-8 sequence.
.../...
Caused by: org.apache.maven.reporting.MavenReportException: Invalid byte 2 of 
3-byte UTF-8 sequence. Nested exception: Invalid byte 2 of 3-byte UTF-8 
sequence.
        at 
org.codehaus.mojo.javancss.NcssReportMojo.loadDocument(NcssReportMojo.java:256)
        at 
org.codehaus.mojo.javancss.NcssReportMojo.loadDocument(NcssReportMojo.java:256)
        at 
org.codehaus.mojo.javancss.NcssReportMojo.loadDocument(NcssReportMojo.java:262)
        at 
org.codehaus.mojo.javancss.NcssReportMojo.generateSingleReport(NcssReportMojo.java:245)
        at 
org.codehaus.mojo.javancss.NcssReportMojo.executeReport(NcssReportMojo.java:158)
        at 
org.apache.maven.reporting.AbstractMavenReport.generate(AbstractMavenReport.java:98)
        at 
org.apache.maven.reporting.AbstractMavenReport.execute(AbstractMavenReport.java:73)
        ... 18 more

> Plugin crashes when Java elements have special characters
> ---------------------------------------------------------
>
>                 Key: MJNCSS-10
>                 URL: http://jira.codehaus.org/browse/MJNCSS-10
>             Project: Maven 2.x JavaNCSS Plugin
>          Issue Type: Bug
>    Affects Versions: 2.0-beta-2
>            Reporter: Fabrice BELLINGARD
>         Assigned To: Jean-Laurent de Morlhon
>             Fix For: 2.0-beta-3
>
>
> One of my team mate found this bug when using a 'é' char on a Java method. 
> When JavaNCSS generates the XML report file, it doesn't specify the file 
> encoding in the <xml> tag (at the very beginning of the file). So when the 
> MOJO reads the report file, it doesn't know which encoding it should use and 
> crashes when reading the report file.
> Looking quickly at the NcssReportMojo class, it looks like specifying the 
> file encoding in the #loadDocument(File file) method should fix the bug (but 
> I haven't tested it):
>    reader.setEncoding(System.getProperty("file.encoding"));

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe from this list please visit:

    http://xircles.codehaus.org/manage_email

Reply via email to