IDEA showing a project twice in tree
<p>I have a Kotlin project with Gradle that has two children. Whenever I try to open it in IDEA, one of the children is shown twice in the tree.</p>

<p><a href="https://i.stack.imgur.com/Uf3ix.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Uf3ix.png" alt="Screenshot"></a></p>

<p>In the tree, you can see two projects at top level, grpc and grp. The issue is that grpc (from top level) is the same project as the grpc that's a children of grp.</p>

<p>Here are my Gradle build files:</p>

<p>The parent gradle.build:</p>

<pre><code>buildscript {
    ext.kotlin_version = '1.0.1'
    repositories {
        jcenter()
        mavenCentral()
    }
    dependencies {
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
}

allprojects {
    repositories {
        jcenter()
        mavenCentral()
    }
} 
</code></pre>

<p>The gradle.settings file:</p>

<pre><code>include ':grpstd', ':grpc'
</code></pre>

<p>The grpc gradle.build:</p>

<pre><code>apply plugin: 'antlr'
apply plugin: 'application'
apply plugin: 'kotlin'

mainClassName = 'sron.grpc.MainKt'

compileKotlin.dependsOn generateGrammarSource

generateGrammarSource {
    arguments += ['-package', 'sron.grpc.compiler.internal']
}

dependencies {
    antlr 'org.antlr:antlr4:4.5.2-1'

    compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
    compile 'commons-cli:commons-cli:1.3.1'
    compile 'org.ow2.asm:asm:5.0.4'
    compile project(':grpstd')

    testCompile 'junit:junit:4.12'
    testCompile "org.jetbrains.kotlin:kotlin-test:$kotlin_version"
}
</code></pre>

<p>The grpstd gradle.build:</p>

<pre><code>apply plugin: 'kotlin'

dependencies {
    compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"

    testCompile 'junit:junit:4.12'
    testCompile "org.jetbrains.kotlin:kotlin-test:$kotlin_version"
}
</code></pre>

<p><strong>Why is that project being shown twice? How can I prevent it?</strong></p>