IDEA keeps forgetting set up modules in run configurations

Answered

Hello,

 

recently I got a weird problem, that IDEA keeps forgetting modules in run configurations. I set up those modules, but I have to set them up quite often. Sometimes when I start IDEA. Sometimes when I change feature branches, although all those modules are available in that feature branch to which I change.

Please have a look at the screenshot I attached. All configuration for JUnit and Spring Boot are reporting that "Module not specified". It seems that IDEA is just forgetting what module I setup before. I checked the forum and tried to search for this issue, but haven't found an issue where it keeps forgetting the specified module. I tried to recreate those run configurations, after some time the same issue appears again.

Did you ever encounter something like that? Do you know how to solve this nagging issue?
Thanks in advance for your time, and in the mean time I keep setting these modules over and over again ;)

Screenshot

Details

IntelliJ IDEA 2018.3.3 (Ultimate Edition)
Build #IU-183.5153.38, built on January 9, 2019
JRE: 1.8.0_152-release-1343-b26 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Windows 10 10.0

0
3 comments

Looks like you are using Gradle. IDE auto-configures the project structure (like module names, dependencies etc) from Gradle configuration when project is re-imported from build.gradle file.

Do module names change when you re-import from Gradle between these branch switches?

Could you try with the version from https://jetbrains.com/idea/download ?

0
Avatar
Permanently deleted user

Hello Andrey,

 

thanks for your reply and thanks for pointing me into the right direction. Indeed Gradle is involved and it turned out that in the build process for Gradle we've been using the IDEA Plugin (https://docs.gradle.org/current/userguide/idea_plugin.html). It was only applied like that:

configure(allprojects) {
apply plugin: "idea"
}

Well, I did not think that it'll be the culprit for other configurations, but it was. Without this plugin, all run configurations keep the module which I setup.

I'll head to gradle and check with them this issue. 

Thanks and have a great Weekend :)

0

Nice finding! Thank you for letting us know. It would be great if you raise an issue Gradle.

0

Please sign in to leave a comment.