maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Karsten Tinnefeld (JIRA)" <>
Subject [jira] Created: (MCHECKSTYLE-159) Optional treeWalker.cacheFile property must not be required
Date Wed, 01 Jun 2011 11:26:22 GMT
Optional treeWalker.cacheFile property must not be required

                 Key: MCHECKSTYLE-159
             Project: Maven 2.x Checkstyle Plugin
          Issue Type: Bug
    Affects Versions: 2.6, 2.7
            Reporter: Karsten Tinnefeld

Given a custom checkstyle configuration, checkstyle requires the property cacheFile to the
TreeWalker module be configured, thus, the following configuration cannot go without the property

<module name="Checker">
  <module name="TreeWalker">
    <property name="cacheFile" value="$\{cachefile\}"/>

In case it is omitted, the tool exits with the following stack trace (shortened, regarding
version 2.6):

[INFO] Error during page generation

Embedded error: Error rendering Maven report: Failed during checkstyle execution
missing key 'cacheFile' in TreeWalker
[INFO] ------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Error during page generation
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(
Caused by: missing key 'cacheFile'
in TreeWalker
	at org.apache.maven.plugin.checkstyle.DefaultCheckstyleExecutor.getConfiguration(
	... 28 more

Due to checkstyle documentation, the property is optional, and no cachefile will be used in
case it is not specified (cf. Also,
cacheFile can be specified in the pom, thus it should be substituted anyway.


Add <configuration/>-Entry


and use the above property line and a special maven build version of the checkstyle configuration

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
For more information on JIRA, see:


View raw message