Issue Details (XML | Word | Printable)

Key: GRAILSPLUGINS-1941
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Chris Mair
Reporter: Neill Robbins
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Grails Plugins

Getting error trying grails codenarc using 0.4 in grails 1.2.1

Created: 09/Feb/10 06:32 AM   Updated: 09/Feb/10 08:29 PM
Component/s: Grails-CodeNarc
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified


 Description  « Hide

Did grails install-plugin which gave me version 0.4
This did fgrails codenarc, and got the below
Mt grails is 1.2.1

Error executing script Codenarc: java.lang.ClassNotFoundException: Config
gant.TargetExecutionException: java.lang.ClassNotFoundException: Config
at gant.Gant$_dispatch_closure4.doCall(Gant.groovy:331)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy:334)
at gant.Gant$_dispatch_closure6.doCall(Gant.groovy)
at gant.Gant.withBuildListeners(Gant.groovy:344)
at gant.Gant.this$2$withBuildListeners(Gant.groovy)
at gant.Gant$this$2$withBuildListeners.callCurrent(Unknown Source)
at gant.Gant.dispatch(Gant.groovy:334)
at gant.Gant.this$2$dispatch(Gant.groovy)
at gant.Gant.invokeMethod(Gant.groovy)
at gant.Gant.processTargets(Gant.groovy:495)
at gant.Gant.processTargets(Gant.groovy:480)
Caused by: java.lang.ClassNotFoundException: Config
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
at Codenarc.loadConfig(Codenarc:58)
at Codenarc.this$4$loadConfig(Codenarc)
at Codenarc$this$4$loadConfig.callCurrent(Unknown Source)
at Codenarc.runCodenarc(Codenarc:29)
at Codenarc.this$4$runCodenarc(Codenarc)
at Codenarc$_run_closure1.doCall(Codenarc:23)
at gant.Gant$_dispatch_closure4.doCall(Gant.groovy:324)
... 10 more
Error executing script Codenarc: java.lang.ClassNotFoundException: Config



Chris Mair added a comment - 09/Feb/10 08:29 PM

This error occurs while trying to load the Config.groovy. Does your Grails app have one? If not, I assume a work-around would be to create that Config.groovy (withing grails-app/conf) – I assume an empty one would be ok.

I will plan on changing the code to not crash if the Config.groovy is missing.

Thanks. - Chris Mair