@SuppressWarnings does not suppress JavadocType violation

279 views
Skip to first unread message

Csaba Kozák

unread,
Sep 27, 2015, 10:34:40 AM9/27/15
to checkstyle
Hey guys! I have this class, and i try to add @SuppressWarnings("checkstyle:javadoctype") but i still have a violation for missing javadoc. My rules are here. Is this a bug or i am doing sg wrong?
The full error message is this: src/main/java/org/androidannotations/api/BackgroundExecutor.java[368] (javadoc) JavadocType: Missing a Javadoc comment.

I am using CS 6.10.1 through the Maven plugin.

Roman Ivanov

unread,
Sep 29, 2015, 9:47:24 PM9/29/15
to Csaba Kozák, checkstyle
Hi Csaba,

Yes , this is a bug of JavadocType check - please report an issue.

It should report violation on class declaration line not to its annotation (that is why Suppression does not work, as it expect violation below itself).
For the sake of simplicity please put to issue a minimized input file and config and prove violation by CLI, like:
18:39 $ java -jar checkstyle-6.11-all.jar -c checkstyle-checks.xml BackgroundExecutor.java 
Starting audit...
/var/tmp/BackgroundExecutor.java:XXXXX: error: Missing a Javadoc comment.
.

thanks,
Roman Ivanov

Csaba Kozák

unread,
Sep 30, 2015, 2:20:35 PM9/30/15
to Roman Ivanov, checkstyle
Hey,

Thanks for the pointers!
Issue reported here.

Regards,
Csaba
Reply all
Reply to author
Forward
0 new messages