Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to import grails 3 project in intellij idea community edition

I was trying to import grails 3 project in intellij idea community edition

I am getting below error

java.lang.NullPointerException at 
com.android.tools.idea.project.messages.AbstractSyncMessages.removeMessages(AbstractSyncMessages.java:79) at 
com.android.tools.idea.gradle.project.sync.messages.GradleSyncMessages.removeProjectMessages(GradleSyncMessages.java:50) at 
com.android.tools.idea.gradle.project.sync.idea.notification.GradleNotificationExtension.customize(GradleNotificationExtension.java:57) at 
com.intellij.openapi.externalSystem.service.notification.ExternalSystemNotificationManager.createNotification(ExternalSystemNotificationManager.java:168) at 
com.intellij.openapi.externalSystem.util.ExternalSystemUtil.createFailureResult(ExternalSystemUtil.java:651) at 
com.intellij.openapi.externalSystem.util.ExternalSystemUtil$3$3.onFailure(ExternalSystemUtil.java:517) at 
com.intellij.openapi.externalSystem.service.remote.ExternalSystemProgressNotificationManagerImpl.onFailure(ExternalSystemProgressNotificationManagerImpl.java:124) at 
com.intellij.openapi.externalSystem.service.internal.ExternalSystemResolveProjectTask.doExecute(ExternalSystemResolveProjectTask.java:94) at 
com.intellij.openapi.externalSystem.service.internal.AbstractExternalSystemTask.execute(AbstractExternalSystemTask.java:163) at 
com.intellij.openapi.externalSystem.service.internal.AbstractExternalSystemTask.execute(AbstractExternalSystemTask.java:149) at 
com.intellij.openapi.externalSystem.util.ExternalSystemUtil$3.execute(ExternalSystemUtil.java:542) at 
com.intellij.openapi.externalSystem.util.ExternalSystemUtil$4.run(ExternalSystemUtil.java:605) at 
com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:750) at 
com.intellij.openapi.progress.impl.CoreProgressManager$5.run(CoreProgressManager.java:434) at 
com.intellij.openapi.progress.impl.CoreProgressManager.lambda$runProcess$1(CoreProgressManager.java:157) at 
com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:580) at 
com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:525) at 
com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:85) at 
com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:144) at 
com.intellij.openapi.application.impl.ApplicationImpl.lambda$null$10(ApplicationImpl.java:565) at 
com.intellij.openapi.application.impl.ApplicationImpl$1.run(ApplicationImpl.java:305) at 
java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at 
java.util.concurrent.FutureTask.run(FutureTask.java:266) at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at 
java.lang.Thread.run(Thread.java:745)  
Consult IDE log for more details (Help | Show Log)
like image 630
Kapil Arora Avatar asked Apr 04 '18 03:04

Kapil Arora


People also ask

Does IntelliJ Community Edition support Grails?

Support for the Grails framework is not bundled with IntelliJ IDEA. You can install the Grails plugin from the JetBrains repository as described in Install plugins. The latest compatible version of IntelliJ IDEA is 2021.3. You can find the documentation for Grails support in earlier versions of IntelliJ IDEA Help.

How do I import a project into IntelliJ Community Edition?

Launch IntelliJ IDEA. If the Welcome screen opens, press Ctrl+Shift+A , type project from existing sources , and click the Import project from existing sources action in the popup. Otherwise, from the main menu, select File | New | Project from Existing Sources.

How do I change my grails version in IntelliJ?

I right clicked on the application and went to Grails -> Change SDK Version. I chose the version I wanted, then IDEA asked me if I wanted to upgrade the application. Clicked yes and all was good.


2 Answers

For me it was a broken (?) link to the JVM, using JAVA_HOME instead of Project JVM solved the issue.

like image 104
dzim Avatar answered Oct 25 '22 22:10

dzim


I solved this by changing the gradle jvm to JAVA_HOME.

like image 43
Yeison Fernando Vega Gómez Avatar answered Oct 25 '22 23:10

Yeison Fernando Vega Gómez