You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the current Eclipse Checkstyle version, it appears that you cannot copy a configuration, make some changes, and then run this copy correctly. A possible reason is that two specific configuration properties are not added to the default (Sun) configuration, while they are in some way already defined as Filter properties. Since it is not clear for me as a user which values these two properties can contain, for now I found a workaround that is also detailed below. This workaround may be helpful to other community users having the same issue.
DETAILS:
Eclipse IDE Version: 2021-03 (4.19.0)
Build id: 20210312-0638
OS: Windows 10, v.10.0, x86_64 / win32
Java version: 15.0.2
Eclipse Checkstyle version 8.44.0.202108061901
REPRODUCTION PATH:
Install Eclipse Checkstyle
Window > Preferences > Checkstyle
Select the "" configuration
Click <Copy...>
In the dialog, click
Click
Open the dialog for a Java project, and select
Select
In the dropdown list, select the "Copy of Sun Checks" configuration you just made
Click
In the "Rebuild suggested" question dialog, Click
-> Outcome = Expected Outcome = OK: The "Copy of Sun Checks" configuration runs correctly.
Now change something in this configuration, e.g. disable a module:
Window > Preferences > Checkstyle
Select the configuration
Click <Configure...>
as an example, select Javadoc Comments, and clear the checkbox for the "JavadocPackage" module
Click
Click
In the "Rebuild ..." question dialog, Click
-> EXPECTED OUTCOME: The configuration runs correctly, and some specific Javadoc Comments (if any) are not reported anymore.
-> OUTCOME: Error Message: "Checkstyle execution failed due to an internal error. Please check error log for details"
-> Error Log: "Checkstyle-Plugin: unable to parse configuration stream".
When having a close look at the Exception Stack Trace, it contains the line:
"Caused by: com.puppycrawl.tools.checkstyle.api.CheckstyleException: Property ${org.checkstyle.sun.suppressionxpathfilter.config} has not been set"
TEMPORARY WORKAROUND:
Remove two specific properties for this configuration, as follows:
Window > Preferences > Checkstyle
Select the configuration
Click <Configure...>
-> Select the module
-> Remove BOTH Modules "SuppressionXpathFilter" and "SuppressionFilter" from the configuration
Click
Click
In the "Rebuild ..." question dialog, Click
-> Outcome = Expected Outcome = OK: The "Copy of Sun Checks" configuration runs correctly.
The text was updated successfully, but these errors were encountered:
ABSTRACT:
In the current Eclipse Checkstyle version, it appears that you cannot copy a configuration, make some changes, and then run this copy correctly. A possible reason is that two specific configuration properties are not added to the default (Sun) configuration, while they are in some way already defined as Filter properties. Since it is not clear for me as a user which values these two properties can contain, for now I found a workaround that is also detailed below. This workaround may be helpful to other community users having the same issue.
DETAILS:
Eclipse IDE Version: 2021-03 (4.19.0)
Build id: 20210312-0638
OS: Windows 10, v.10.0, x86_64 / win32
Java version: 15.0.2
Eclipse Checkstyle version 8.44.0.202108061901
REPRODUCTION PATH:
-> Outcome = Expected Outcome = OK: The "Copy of Sun Checks" configuration runs correctly.
Now change something in this configuration, e.g. disable a module:
-> EXPECTED OUTCOME: The configuration runs correctly, and some specific Javadoc Comments (if any) are not reported anymore.
-> OUTCOME: Error Message: "Checkstyle execution failed due to an internal error. Please check error log for details"
-> Error Log: "Checkstyle-Plugin: unable to parse configuration stream".
When having a close look at the Exception Stack Trace, it contains the line:
"Caused by: com.puppycrawl.tools.checkstyle.api.CheckstyleException: Property ${org.checkstyle.sun.suppressionxpathfilter.config} has not been set"
TEMPORARY WORKAROUND:
Remove two specific properties for this configuration, as follows:
-> Select the module
-> Remove BOTH Modules "SuppressionXpathFilter" and "SuppressionFilter" from the configuration
-> Outcome = Expected Outcome = OK: The "Copy of Sun Checks" configuration runs correctly.
The text was updated successfully, but these errors were encountered: