Cannot set property 'blockTypes' in module ChildBlockLength #351

Closed
rdiachenko opened this Issue Jun 10, 2015 · 0 comments

Projects

None yet

2 participants

@rdiachenko
Member
<module name="ChildBlockLength">
      <property name="severity" value="warning"/>
      <property name="blockTypes" value="LITERAL_IF,LITERAL_ELSE,LITERAL_WHILE,LITERAL_DO,LITERAL_FOR,LITERAL_SWITCH,LITERAL_TRY,LITERAL_CATCH"/>
</module>
Caused by: com.puppycrawl.tools.checkstyle.api.CheckstyleException: Cannot set property 'blockTypes' in module ChildBlockLength to 'LITERAL_IF,LITERAL_ELSE,LITERAL_WHILE,LITERAL_DO,LITERAL_FOR,LITERAL_SWITCH,LITERAL_TRY,LITERAL_CATCH': com.puppycrawl.tools.checkstyle.api.TokenTypes.getTokenId(Ljava/lang/String;)I
        at com.puppycrawl.tools.checkstyle.api.AutomaticBean.configure(AutomaticBean.java:150)
        at com.puppycrawl.tools.checkstyle.TreeWalker.setupChild(TreeWalker.java:170)
        at com.puppycrawl.tools.checkstyle.api.AutomaticBean.configure(AutomaticBean.java:171)
        at com.puppycrawl.tools.checkstyle.Checker.setupChild(Checker.java:160)
        ... 28 more
Caused by: java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:497)
        at org.apache.commons.beanutils.PropertyUtilsBean.invokeMethod(PropertyUtilsBean.java:2170)
        at org.apache.commons.beanutils.PropertyUtilsBean.setSimpleProperty(PropertyUtilsBean.java:2151)
        at org.apache.commons.beanutils.BeanUtilsBean.copyProperty(BeanUtilsBean.java:439)
        at com.puppycrawl.tools.checkstyle.api.AutomaticBean.configure(AutomaticBean.java:147)

Reproduced on:
checkstyle 6.7
sevntu-checkstyle 1.13.3

@oyarzun oyarzun added a commit to oyarzun/sevntu.checkstyle that referenced this issue Jun 23, 2015
@oyarzun oyarzun Update to checkstyle 6.7 Fixes #351
TokenTypes methods getTokenId() and getTokenName() moved to Utils in
checkstyle 6.7.

DefaultLogger now trows UnsupportedEncodingExpection in 6.7.
1bde78b
@romani romani added a commit that closed this issue Sep 7, 2015
@oyarzun @romani oyarzun + romani Update to checkstyle 6.7 Fixes #351
TokenTypes methods getTokenId() and getTokenName() moved to Utils in
checkstyle 6.7.

DefaultLogger now trows UnsupportedEncodingExpection in 6.7.
247addb
@romani romani closed this in 247addb Sep 7, 2015
@romani romani added this to the 1.13.6 milestone Sep 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment