You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Vincent Massol (JIRA)" <ji...@codehaus.org> on 2005/10/06 11:33:11 UTC

[jira] Created: (MNG-1111) useFile property does not seem to work

useFile property does not seem to work
--------------------------------------

         Key: MNG-1111
         URL: http://jira.codehaus.org/browse/MNG-1111
     Project: Maven 2
        Type: Bug
  Components: maven-checkstyle-plugin  
    Versions: 2.0-beta-3    
 Reporter: Vincent Massol


    /**
     * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
     * created with the violations. Note: This is in addition to the XML result file (containing
     * the violations in XML format which is always created.
     *
     * @parameter
     */
    private File useFile;

However it seems the useFile properties not "null" by default as nothing is printed on the console:

C:\dev\cargo\original_trunk\core\util>m2 install -o
[INFO]
NOTE: Maven is executing in offline mode. Any artifacts not already in your local
repository will be inaccessible.

[INFO] ----------------------------------------------------------------------------
[INFO] Building Cargo Core Util API
[INFO]    task-segment: [install]
[INFO] ----------------------------------------------------------------------------
[INFO] [checkstyle:checkstyle {execution: default}]
[INFO] ----------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ----------------------------------------------------------------------------
[INFO] Diagnosis: An error has occurred in Checkstyle report generation.
[INFO] ----------------------------------------------------------------------------
[INFO] ----------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Updated: (MNG-1111) useFile property does not seem to work

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1111?page=all ]

Brett Porter updated MNG-1111:
------------------------------

    Fix Version: 2.0-beta-4

> useFile property does not seem to work
> --------------------------------------
>
>          Key: MNG-1111
>          URL: http://jira.codehaus.org/browse/MNG-1111
>      Project: Maven 2
>         Type: Bug
>   Components: maven-checkstyle-plugin
>     Versions: 2.0-beta-3
>     Reporter: Vincent Massol
>      Fix For: 2.0-beta-4

>
>
>     /**
>      * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
>      * created with the violations. Note: This is in addition to the XML result file (containing
>      * the violations in XML format which is always created.
>      *
>      * @parameter
>      */
>     private File useFile;
> However it seems the useFile properties not "null" by default as nothing is printed on the console:
> C:\dev\cargo\original_trunk\core\util>m2 install -o
> [INFO]
> NOTE: Maven is executing in offline mode. Any artifacts not already in your local
> repository will be inaccessible.
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Cargo Core Util API
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [checkstyle:checkstyle {execution: default}]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Diagnosis: An error has occurred in Checkstyle report generation.
> [INFO] ----------------------------------------------------------------------------
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Commented: (MNG-1111) useFile property does not seem to work

Posted by "Vincent Massol (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-1111?page=comments#action_47950 ] 

Vincent Massol commented on MNG-1111:
-------------------------------------

It does go the checkstyle. I'm getting:


C:\dev\cargo\original_trunk\core\util>m2 install -o -X
+ Error stacktraces are turned on.
[DEBUG] Building Maven user-level plugin registry from: 'C:\Documents and Settings\Vincent Massol\.m2\plugin-registry.xml'
[DEBUG] Building Maven global-level plugin registry from: 'c:\apps\maven2\conf\plugin-registry.xml'
[INFO]
NOTE: Maven is executing in offline mode. Any artifacts not already in your local
repository will be inaccessible.

[DEBUG] Using parent-POM from the project hierarchy at: '../pom.xml' for project: null:cargo-core-util:jar:null
[DEBUG] Using parent-POM from the project hierarchy at: '../pom.xml' for project: org.codehaus.cargo.core:cargo-core:jar:null
[INFO] ----------------------------------------------------------------------------
[INFO] Building Cargo Core Util API
[INFO]    task-segment: [install]
[INFO] ----------------------------------------------------------------------------
[DEBUG] maven-resources-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] Skipping disabled repository central
[DEBUG] maven-resources-plugin: using locally installed snapshot
[DEBUG] maven-resources-plugin: using locally installed snapshot
[DEBUG] maven-compiler-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] Skipping disabled repository central
[DEBUG] maven-compiler-plugin: using locally installed snapshot
[DEBUG] maven-compiler-plugin: using locally installed snapshot
[DEBUG] maven-surefire-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] Skipping disabled repository central
[DEBUG] Skipping disabled repository central
[DEBUG] maven-surefire-plugin: using locally installed snapshot
[DEBUG] maven-surefire-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] maven-surefire-plugin: using locally installed snapshot
[DEBUG] maven-jar-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] Skipping disabled repository central
[DEBUG] maven-jar-plugin: using locally installed snapshot
[DEBUG] maven-jar-plugin: using locally installed snapshot
[DEBUG] maven-install-plugin: resolved to version 2.0-beta-2-SNAPSHOT from repository central
[DEBUG] Skipping disabled repository central
[DEBUG] maven-install-plugin: using locally installed snapshot
[DEBUG] maven-install-plugin: using locally installed snapshot
[DEBUG] maven-checkstyle-plugin: resolved to version 2.0-alpha-3-SNAPSHOT from local repository
[DEBUG] Skipping disabled repository central
[DEBUG] maven-checkstyle-plugin: using locally installed snapshot
[DEBUG] Skipping disabled repository central
[DEBUG] maven-plugin-parent: using locally installed snapshot
[DEBUG] maven-checkstyle-plugin: using locally installed snapshot
[DEBUG] org.apache.maven.plugins:maven-checkstyle-plugin:maven-plugin:2.0-alpha-3-SNAPSHOT (selected for runtime)
[DEBUG]   commons-logging:commons-logging:jar:1.0.3 (selected for runtime)
[DEBUG]     junit:junit:jar:3.7 (selected for runtime)
[DEBUG]     logkit:logkit:jar:1.0.1 (selected for runtime)
[DEBUG]     log4j:log4j:jar:1.2.6 (selected for runtime)
[DEBUG]   org.apache.maven.reporting:maven-reporting-impl:jar:2.0-beta-1 (selected for runtime)
[DEBUG]     commons-validator:commons-validator:jar:1.1.4 (selected for runtime)
[DEBUG]     oro:oro:jar:2.0.7 (selected for runtime)
[DEBUG]     doxia:doxia-core:jar:1.0-alpha-4 (selected for runtime)
[DEBUG]       oro:oro:jar:2.0.7 (removed - nearer found: 2.0.7)
[DEBUG]       oro:oro:jar:2.0.7 (selected for runtime)
[DEBUG]   checkstyle:checkstyle-optional:jar:3.4 (selected for runtime)
[DEBUG]   commons-collections:commons-collections:jar:2.1 (selected for runtime)
[DEBUG]     junit:junit:jar:3.7 (removed - nearer found: 3.7)
[DEBUG]     junit:junit:jar:3.7 (selected for runtime)
[DEBUG]   checkstyle:checkstyle:jar:3.4 (selected for runtime)
[DEBUG]   commons-beanutils:commons-beanutils:jar:1.6.1 (selected for runtime)
[DEBUG]     junit:junit:jar:3.7 (removed - nearer found: 3.7)
[DEBUG]     junit:junit:jar:3.7 (selected for runtime)
[DEBUG]     commons-logging:commons-logging:jar:1.0 (removed - nearer found: 1.0.3)
[DEBUG]     commons-logging:commons-logging:jar:1.0 (selected for runtime)
[DEBUG]     commons-collections:commons-collections:jar:2.0 (removed - nearer found: 2.1)
[DEBUG]     commons-collections:commons-collections:jar:2.0 (selected for runtime)
[DEBUG]   regexp:regexp:jar:1.3 (selected for runtime)
[DEBUG]   antlr:antlr:jar:2.7.2 (selected for runtime)
[INFO] [checkstyle:checkstyle {execution: default}]
[INFO] ----------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ----------------------------------------------------------------------------
[INFO] Diagnosis: An error has occurred in Checkstyle report generation.
[INFO] ----------------------------------------------------------------------------
[DEBUG] Trace:

org.apache.maven.plugin.MojoExecutionException: An error has occurred in Checkstyle report generation.
        at org.apache.maven.reporting.AbstractMavenReport.execute(AbstractMavenReport.java:98)
        at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:406)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:513)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:499)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:312)
        at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:154)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:217)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:237)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.reporting.MavenReportException: There are 274 formatting errors.
        at org.apache.maven.plugin.checkstyle.CheckstyleReport.executeReport(CheckstyleReport.java:296)
        at org.apache.maven.reporting.AbstractMavenReport.generate(AbstractMavenReport.java:117)
        at org.apache.maven.reporting.AbstractMavenReport.execute(AbstractMavenReport.java:92)
        ... 16 more
[INFO] ----------------------------------------------------------------------------
[INFO] ----------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ----------------------------------------------------------------------------
[INFO] Total time: 4 seconds
[INFO] Finished at: Thu Oct 06 11:41:30 CEST 2005
[INFO] Final Memory: 3M/6M
[INFO] ----------------------------------------------------------------------------

The other issue is that my checkstyle.xml file is read (it fails if I use a different relative path) but it doesn't seem to be used (there should be 0 errors).

> useFile property does not seem to work
> --------------------------------------
>
>          Key: MNG-1111
>          URL: http://jira.codehaus.org/browse/MNG-1111
>      Project: Maven 2
>         Type: Bug
>   Components: maven-checkstyle-plugin
>     Versions: 2.0-beta-3
>     Reporter: Vincent Massol
>      Fix For: 2.0-beta-4

>
>
>     /**
>      * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
>      * created with the violations. Note: This is in addition to the XML result file (containing
>      * the violations in XML format which is always created.
>      *
>      * @parameter
>      */
>     private File useFile;
> However it seems the useFile properties not "null" by default as nothing is printed on the console:
> C:\dev\cargo\original_trunk\core\util>m2 install -o
> [INFO]
> NOTE: Maven is executing in offline mode. Any artifacts not already in your local
> repository will be inaccessible.
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Cargo Core Util API
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [checkstyle:checkstyle {execution: default}]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Diagnosis: An error has occurred in Checkstyle report generation.
> [INFO] ----------------------------------------------------------------------------
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Closed: (MNG-1111) useFile property does not seem to work

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1111?page=all ]
     
Brett Porter closed MNG-1111:
-----------------------------

    Resolution: Fixed

applied with modifications - logging to a string and using getLog() at end instead of system.out

> useFile property does not seem to work
> --------------------------------------
>
>          Key: MNG-1111
>          URL: http://jira.codehaus.org/browse/MNG-1111
>      Project: Maven 2
>         Type: Bug
>   Components: maven-checkstyle-plugin
>     Versions: 2.0-beta-3
>     Reporter: Vincent Massol
>     Assignee: Edwin Punzalan
>      Fix For: 2.0-beta-4
>  Attachments: MNG-1111-maven-checkstyle-plugin.patch
>
>
>     /**
>      * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
>      * created with the violations. Note: This is in addition to the XML result file (containing
>      * the violations in XML format which is always created.
>      *
>      * @parameter
>      */
>     private File useFile;
> However it seems the useFile properties not "null" by default as nothing is printed on the console:
> C:\dev\cargo\original_trunk\core\util>m2 install -o
> [INFO]
> NOTE: Maven is executing in offline mode. Any artifacts not already in your local
> repository will be inaccessible.
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Cargo Core Util API
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [checkstyle:checkstyle {execution: default}]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Diagnosis: An error has occurred in Checkstyle report generation.
> [INFO] ----------------------------------------------------------------------------
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Updated: (MNG-1111) useFile property does not seem to work

Posted by "Edwin Punzalan (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MNG-1111?page=all ]

Edwin Punzalan updated MNG-1111:
--------------------------------

    Attachment: MNG-1111-maven-checkstyle-plugin.patch

> useFile property does not seem to work
> --------------------------------------
>
>          Key: MNG-1111
>          URL: http://jira.codehaus.org/browse/MNG-1111
>      Project: Maven 2
>         Type: Bug
>   Components: maven-checkstyle-plugin
>     Versions: 2.0-beta-3
>     Reporter: Vincent Massol
>     Assignee: Edwin Punzalan
>      Fix For: 2.0-beta-4
>  Attachments: MNG-1111-maven-checkstyle-plugin.patch
>
>
>     /**
>      * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
>      * created with the violations. Note: This is in addition to the XML result file (containing
>      * the violations in XML format which is always created.
>      *
>      * @parameter
>      */
>     private File useFile;
> However it seems the useFile properties not "null" by default as nothing is printed on the console:
> C:\dev\cargo\original_trunk\core\util>m2 install -o
> [INFO]
> NOTE: Maven is executing in offline mode. Any artifacts not already in your local
> repository will be inaccessible.
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Cargo Core Util API
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [checkstyle:checkstyle {execution: default}]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Diagnosis: An error has occurred in Checkstyle report generation.
> [INFO] ----------------------------------------------------------------------------
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Commented: (MNG-1111) useFile property does not seem to work

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/MNG-1111?page=comments#action_47946 ] 

Brett Porter commented on MNG-1111:
-----------------------------------

I'm not sure you even got to checkstyle. We've discovered an issue with the plugin errors being swallowed as you see here. What does -X show?

> useFile property does not seem to work
> --------------------------------------
>
>          Key: MNG-1111
>          URL: http://jira.codehaus.org/browse/MNG-1111
>      Project: Maven 2
>         Type: Bug
>   Components: maven-checkstyle-plugin
>     Versions: 2.0-beta-3
>     Reporter: Vincent Massol

>
>
>     /**
>      * If null, the checkstyle task will display violations on stdout. Otherwise, the text file will be
>      * created with the violations. Note: This is in addition to the XML result file (containing
>      * the violations in XML format which is always created.
>      *
>      * @parameter
>      */
>     private File useFile;
> However it seems the useFile properties not "null" by default as nothing is printed on the console:
> C:\dev\cargo\original_trunk\core\util>m2 install -o
> [INFO]
> NOTE: Maven is executing in offline mode. Any artifacts not already in your local
> repository will be inaccessible.
> [INFO] ----------------------------------------------------------------------------
> [INFO] Building Cargo Core Util API
> [INFO]    task-segment: [install]
> [INFO] ----------------------------------------------------------------------------
> [INFO] [checkstyle:checkstyle {execution: default}]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Diagnosis: An error has occurred in Checkstyle report generation.
> [INFO] ----------------------------------------------------------------------------
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------

-- 
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, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org