intellij idea – How can my Gradle build initialize class org.codehaus.groovy.classgen.Verifier?

intellij idea – How can my Gradle build initialize class org.codehaus.groovy.classgen.Verifier?

Ive been facing the exactly same issue after installing the latest Kotlin Plugin yesterday. This is what resolved the issue for me: I had to change the version of Gradle used as the build tool to (again) use the version installed on my local system. It seems to me that installing the update has caused my settings to be changed as well.

For doing to open your settings (File -> Settings) and navigate to the Gradle settings (Build, Execution, Deployment -> Build Tools -> Gradle)

There you will see a dropdown for Use Gradle from:. This for me was set to the gradle-wrapper.properties file which it couldnt locate. I changed the selected value to Specified location and ensured that the path which is then displayed is the path to my local Gradle installation. Finally click OK to save the settings.

This is what resolved the issue for me. Hope this helps!

For documentation purposes let me also include the different versions of the tooling on my system (truncated):

IntelliJ IDEA 2020.1 (Community Edition)
Build #IC-201.6668.121, built on April 8, 2020
Runtime version: 11.0.6+8-b765.25 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
...
Non-Bundled Plugins: org.jetbrains.kotlin`

Kotlin Plugin 1.3.72-release-IJ2020.1-1

Gradle 6.3
Build time:   2020-03-24 19:52:07 UTC
...
Kotlin:       1.3.70
Groovy:       2.5.10
Ant:          Apache Ant(TM) version 1.10.7 compiled on September 1 2019

You have to use a more recent version of Gradle:

you can change the distributionUrl to

distributionUrl=https://services.gradle.org/distributions/gradle-6.4.1-bin.zip

in gradlewrappergradle-wrapper.properties (or wherever your use gradle from in the settings is pointing to).

intellij idea – How can my Gradle build initialize class org.codehaus.groovy.classgen.Verifier?

You can manually download the latest version of Gradle (https://services.gradle.org/distributions/), unzip it in your JavaVirtualMachines folder, then in IntelliJ navigate to Preferences>Build,Execution,Deployment>Gradle. Find Use Gradle From then choose specified location from drop down, and in the box to the right, JavaVirtualMachines location with your gradle folder (for me it was gradle-6.8-rc-1-all.zip). Choose that folder, your system will rebuild and download dependancies, and the error will die.

  1. Navigate to https://services.gradle.org/distributions/
  2. Download gradle-6.8-rc-1-all.zip (or newer)
  3. Unzip and place in /Library/Java/JavaVirtualMachines/
  4. IntelliJ->Preferences->Build,Execution,Deployment->Gradle
  5. Choose Specified Folder
  6. Designate gradle-6.8-rc-1-all folder as target
  7. Profit

Leave a Reply

Your email address will not be published.