Grails SDK Not found when Viewing 2 Projects in 2 Windows?

Anyone else see an issue with one project (not always the same one) complaining about the Grails SDK Not being found when you have two Grails projects open in two different IDE windows?

Basically, I have Project A with Grails 2.3.5, and Project B with Grails 2.4.0.

I'm actively working on both projects and so have each one open in a separate IDE Window.

When I shutdown the IDE and restart it, one of the projects (not always the same one) says that the Grails SDK is not found, and an actionable link is provided to configure it.

If I click that link and configure the Grails Library and then go to the module settings, I see the Grails Library included twice in the project.

If I delete one of the duplicated and leave the IDE open, everything is fine, but every time I shutdown and restart the IDE, the error reoccurs.

I'm on a Mac (OSX 10.9.3) and IntelliJ Ultimate 13.1.3.

I contacted support but they weren't able to reproduce it.

I've disabled all 3rd party plugins (though I only had one, Markdown).

Just wanted to see if anyone else in the community is able to reproduce the issue?

Thanks, any help would be greatly apprecated.

Screen Shot 2014-06-01 at 11.59.07 PM.png
Screen Shot 2014-06-01 at 11.58.52 PM.png
Screen Shot 2014-06-01 at 11.58.41 PM.png
Comment actions Permalink

I cannot offer any assistance, I'm afraid, but can add my similar experience.

I'm using IDEA 13.1 build 760 and have a couple of Grails v2.3.7 projects. I've just downloaded v2.4 and wanted to upgrade the projects to 2.4, I'm not continuing with 2.3.7 so I changed GRAILS_HOME as well. First I created a clean grails 2.4 application and 2.4 plugin project; the application was fine but the plugin seemed to loose it's Grailsness - came up with SDK not defined but the 'link' didn't actually seem to go anywhere but when I closed and re-opened IDEA it was back as a Grails project. I also noticed, but that may have been my mistake, that there were two Grails 2.4 'libraries'. But after clearing up a little both projects seemed to be correct.

I then opened the 2.3.7 plugin project that I have, and went straight to update SDK - and it did nothing - other than briefly show the 'SDK not defined message' and I now have a project that is not Grails at all despite Grails 2.4 being listed in Project Structure/Modules. I have had problems before taking some projects through a Grails update but not every time; and I have cleared everything out and ran the 'create project from existing sources' more than once.

I did wonder whether there were problems with Grails 2.4 and IDEA ?

Oh, and I'm on linux, Xubuntu 12.04, JDK 1.7_45


Comment actions Permalink

Well, perhaps one should read everything first - but this may not explain the whole issue, anyway.

I did run 'create project from existing sources'  and then noticed that it failed when it tried to run the Grails 'upgrade' command; it appears that this has been withdrawn - see

My concern is, of course, that I'm not running the very latest IDEA and so ....

However it's very obvious that this failure was occurring when I was attempting to run the 'upgrade SDK' option within IDEA but the error was not being shown on the screen - I have noticed that not infrequently the console is not shown when Grails commands are runing which does irritate.


Comment actions Permalink

Hi Eric - I do apologise for somewhat hijacking your thread with a seemingly similar problem but actually somewhat rather different - and I've created a new discussion about that.

However to return to your actual problem: do you just close IDEA with the project(s) open and then restart it again so it goies into the open project(s) ?

I ask because some versions ago I got irritated with IDEA having focus on the 'wrong' project (when I had more that one project open)  and I am now in the habit of always closing the projects manually so that I finally close IDEA at a stage where it has no open projects. At least that means that when I restart it I know where it is going to start from. I wonder whether that may help in your situation.

But I still do get a little irritated with running commands from the 'FiIe...' menu bar and finding that IDEA had the 'wrong' focus because I wasn't paying attention.


Comment actions Permalink

Hi Graham, No problem, I've seen your issue before too, and like you just recreated the project and it seemed to work fine going forward.

Yes, I just quit the IDE with both projects open, so that when I restart the IDE both projects open again in two separate windows.

I'll try closing the projects manually and separately before quitting the IDE and see if that helps, but might end up leaving it alone - it only takes a few seconds to re-configure the SDK, it's just annoying to have to do it.


Please sign in to leave a comment.