6

I upgrade to Grails 2.4.2 because that supposedly fixes a bug with the maven plugin that caused it to generate a bad pom.xml file. Now, when I try to run the 2.4.2-generated pom with mvn clean install I get the following error message:

[ERROR] Failed to execute goal org.grails:grails-maven-plugin:2.4.2:maven-compile (default-maven-compile) on project PROJECT : Failed to create classpath for Grails execution. Failure to find org.codehaus.groovy:groovy-all:jar:2.4.2 in https://REPO was cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced -> [Help 1]

Groovy 2.4.2 obvious doesn't exist since 2.3.X is the latest release. How do I force the maven plugins to take 2.3.2's groovy-all package as the dependency to use for Groovy?

Mike Thomsen
  • 36,828
  • 10
  • 60
  • 83
  • Just came across same issue. I've added a JIRA to the Grails project: https://jira.grails.org/browse/GRAILS-11544. – Stuart Watt Jun 30 '14 at 17:48

1 Answers1

7

Solution: it was a bug in the Maven plugin. I sent a code fix to the owner.

Update: I sent a bug fix that was incorporated into Grails. The new dependency is org.grails:grails-maven-plugin:2.4.3. You should update your Grails BuildConfig and the pom file (or regenerate it).

Mike Thomsen
  • 36,828
  • 10
  • 60
  • 83
  • Did you find a workaround for this? I can see there was a fix, and Graeme suggested adding a dependency as a workaround, but that doesn't seem to get it past this point. If you have a workaround, I'd be very grateful if you could post it. – Stuart Watt Jul 03 '14 at 22:07
  • 2
    Ah, problem solved. `org.grails:grails-maven-plugin:2.4.3` is now out. Using that in the POM resolves the issue. No dependencies seem to be needed, either. – Stuart Watt Jul 04 '14 at 13:24
  • 1
    @StuartWatt Unfortunately this is not fixed in the current release. I am a first time grails user and adding this dep doesn't fix it (intellij finds the dep, but when running it still wants the old groovy jar). Am I missing something? – Patrick Oct 05 '14 at 21:45