@Property annotation removed

Generated code in Grails used to use an @Property annotation to indicate Grails properties. This was used somewhere around version 0.1 – 0.2, was still supported in 0.3.1 (although I think not used in newly generated code), but is now no longer in 0.4.2. You’ll see the error:

<code>
 @ line 8, column 6.ExampleController: 34: unable to resolve class Property unable
to find class for annotation
</code>

Just go through your old code if you have migrated from prior versions of Grails and replace the @Property annotation with def instead – the code will work with 0.4.2+.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.