This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 245928 - Annotation processor fails with CAL10N
Summary: Annotation processor fails with CAL10N
Status: RESOLVED WONTFIX
Alias: None
Product: java
Classification: Unclassified
Component: Compiler (show other bugs)
Version: 8.0.1
Hardware: PC Linux
: P3 normal (vote)
Assignee: Dusan Balek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-23 21:40 UTC by nagure
Modified: 2016-07-07 07:15 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Sample Maven project which reproduces the reported issue. (3.60 KB, application/zip)
2014-07-23 21:40 UTC, nagure
Details

Note You need to log in before you can comment on or make changes to this bug.
Description nagure 2014-07-23 21:40:35 UTC
Created attachment 148247 [details]
Sample Maven project which reproduces the reported issue.

This message was originated from a post in nbusers@netbeans.org, which I reproduce as follows:

----------------------

[...]

I use a library named CAL10N (http://cal10n.qos.ch/) in one of our projects. In short, instead of using String typed keys for localized messages, CAL10N uses enums. According to the documentation (http://cal10n.qos.ch/manual.html#jsr269):

"As of version 0.8, CAL10N ships with an JSR-269 compliant annotation processor named CAL10NAnnotationProcessor. By enabling this processor you can have javac, i.e. the java compiler, report discrepancies in your bundles at compile-time without leaving your favorite IDE. The verification is triggered at every compilation of an enum class annotated with @BaseName."

This particular project is Maven-powered. If I reproduce the tutorial from the manual, NetBeans keep complaining about failing to locate the resource bundle specified in @BaseName. The paths are correct, and the project correctly compiles from command line with Maven. Apparently, Eclipse had a similar behaviour in past versions of this library (http://cal10n.qos.ch/news.html):

"This release adds JSR-269 support. In other words, verification of bundles can be performed at compilation time. See the related documentation for more details. Fix issue with Eclipse not finding existing resources. With release 0.8.1, Eclipse will find bundles located under "src/main/resources" but still fail to find bundles located under "src/test/resources/"."

In fact, if I try to open my project in Eclipse (Luna), there are no errors pointed by annotation processor.

The ugly workaround was to include a "wrong" entry in my pom.xml's processor, so NetBeans "ignores" the check. But to be honest, I was expecting to use this analysis to my own benefit.

Current scheme:
NetBeans 8.0, applied all updates so far.
Linux Fedora 20, 32 bits.
Java 1.7.0_65, OpenJDK

----------------------

I attached a sample Maven project based on the CAL10N tutorial available from their manual which reproduces the issue in NetBeans. The enum Colors is marked as containing errors when, in fact, there is none.

All the best,

Rafa
Comment 1 Martin Balin 2016-07-07 07:15:39 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss