kotlin-dsl-samples
kotlin-dsl-samples copied to clipboard
Unsupported declaration type: VALUE_PARAMETER
Let me start off by apologizing because this is by no means a minimalist code example. I will see what I can do to create a smaller example at some point in the future. I just wanted to start by making sure that I captured the bug somewhere.
Unfortunately, the exception that I get doesn't tell me what line the problem is coming from.
Expected Behavior
I have a subproject build file that looks something like this:
import com.bmuschko.gradle.docker.tasks.container.DockerCreateContainer
import com.bmuschko.gradle.docker.tasks.container.DockerRemoveContainer
import com.bmuschko.gradle.docker.tasks.container.DockerStartContainer
import com.bmuschko.gradle.docker.tasks.container.DockerStopContainer
import com.bmuschko.gradle.docker.tasks.image.DockerPullImage
import com.bmuschko.gradle.docker.tasks.DockerVersion
import java.net.Socket
buildscript {
dependencies {
classpath("com.bmuschko:gradle-docker-plugin:${property("gradle_docker_plugin.version")}")
}
}
apply {
plugin("com.bmuschko.docker-remote-api")
}
description = """
Manages all configuration and communication with the message broker.
""".trimMargin()
dependencies {
compile(group = "com.rabbitmq", name = "amqp-client", version = "4.1.0")
compile(group = "net.jodah", name = "failsafe", version = "1.0.4")
compile(group = "com.natpryce", name = "konfig", version = "1.6.1.0")
compile(group = "io.github.microutils", name = "kotlin-logging", version = "1.4.4")
compile(project(":DependencyInjection"))
}
fun isPortInUse(hostName : String, portNumber : Int) = try {
Socket(hostName, portNumber).close()
true
} catch (exception : Exception) {
false
}
val isRabbitmqRunning = isPortInUse("localhost", 5672)
fun Task.skipIfRabbitmqRunning() {
onlyIf {
!isRabbitmqRunning
}
}
/**
* Workaround for:
* - https://github.com/gradle/kotlin-dsl/issues/593
* - https://github.com/bmuschko/gradle-docker-plugin/issues/495
*/
class CustomKotlinClosure1<in T : Any?, V : Any>(
val function: T.() -> V?,
owner: Any? = null,
thisObject: Any? = null) : groovy.lang.Closure<V?>(owner, thisObject) {
@Suppress("unused") // to be called dynamically by Groovy
fun doCall(it: T): V? = it.function()
}
/*
* We want to make it possible to run the build without docker installed.
* We do so by adding the ability to specify a `-PskipDocker` or `-PskipDocker=true` flag when executing gradle.
* When specified this will skip the docker tasks and will not run any tasks dependent upon Docker running.
*/
val skipDockerPropertyName = "skipDocker"
val skipDocker = hasProperty(skipDockerPropertyName) && property(skipDockerPropertyName) != "false"
fun Task.skipIfSkipDockerSpecified() {
onlyIf { !skipDocker }
}
val getDockerVersion = task<DockerVersion>("getDockerVersion") {
onError = CustomKotlinClosure1<Exception?, Unit> ({
if (this == null) {
// TODO: Fix after this is resolved: https://github.com/bmuschko/gradle-docker-plugin/issues/490
return@CustomKotlinClosure1 Unit
}
val message = "Docker is not installed or is not running."
if (skipDocker) {
logger.error("$message Skipping Docker dependent tasks.")
} else {
throw GradleException("$message To skip Docker tasks run with -P$skipDockerPropertyName flag.")
}
})
}
val pullRabbitmqContainer = task<DockerPullImage>("pullRabbitmq") {
tag = "latest"
repository = "rabbitmq"
dependsOn(getDockerVersion)
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val createRabbitmqContainer = task<DockerCreateContainer>("createRabbitmq") {
dependsOn(pullRabbitmqContainer)
portBindings = listOf("5672:5672")
targetImageId {
pullRabbitmqContainer.run { if (tag != null) "$repository:$tag" else repository }
}
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val startRabbitmqContainer = task<DockerStartContainer>("startRabbitmq") {
dependsOn(createRabbitmqContainer)
targetContainerId { createRabbitmqContainer.containerId }
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val removeRabbitmqContainer = task<DockerRemoveContainer>("removeRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
}
val stopRabbitmqContainer = task<DockerStopContainer>("stopRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
finalizedBy(removeRabbitmqContainer)
}
afterEvaluate {
tasks.getByName("junitPlatformTest") {
dependsOn(startRabbitmqContainer)
finalizedBy(stopRabbitmqContainer)
skipIfSkipDockerSpecified()
}
}
I can compile it fine with Gradle but IntelliJ doesn't do syntax highlighting correctly on the file.
Current Behavior
I get this exception in the IntelliJ log files
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - Unsupported declaration type: VALUE_PARAMETER File name: MessageBroker.gradle.kts Physical: true Injected: false
buildscript {
dependencies {
classpath("com.bmuschko:gradle-docker-plugin:${property("gradle_docker_plugin.version")}")
}
}
apply {
plugin("com.bmuschko.docker-remote-api")
}
description = """
Manages all configuration and communication with the message broker.
""".trimMargin()
dependencies {
compile(group = "com.rabbitmq", name = "amqp-client", version = "4.1.0")
compile(group = "net.jodah", name = "failsafe", version = "1.0.4")
compile(group = "com.natpryce", name = "konfig", version = "1.6.1.0")
compile(group = "io.github.microutils", name = "kotlin-logging", version = "1.4.4")
compile(project(":DependencyInjection"))
}
fun isPortInUse(hostName : String, portNumber : Int) = try {
Socket(hostName, portNumber).close()
true
} catch (<caret>exception : Exception) {
false
}
val isRabbitmqRunning = isPortInUse("localhost", 5672)
fun Task.skipIfRabbitmqRunning() {
onlyIf {
!isRabbitmqRunning
}
}
/**
* Workaround for:
* - https://github.com/gradle/kotlin-dsl/issues/593
* - https://github.com/bmuschko/gradle-docker-plugin/issues/495
*/
class CustomKotlinClosure1<in T : Any?, V : Any>(
val function: T.() -> V?,
owner: Any? = null,
thisObject: Any? = null) : groovy.lang.Closure<V?>(owner, thisObject) {
@Suppress("unused") // to be called dynamically by Groovy
fun doCall(it: T): V? = it.function()
}
/*
* We want to make it possible to run the build without docker installed.
* We do so by adding the ability to specify a `-PskipDocker` or `-PskipDocker=true` flag when executing gradle.
* When specified this will skip the docker tasks and will not run any tasks dependent upon Docker running.
*/
val skipDockerPropertyName = "skipDocker"
val skipDocker = hasProperty(skipDockerPropertyName) && property(skipDockerPropertyName) != "false"
fun Task.skipIfSkipDockerSpecified() {
onlyIf { !skipDocker }
}
val getDockerVersion = task<DockerVersion>("getDockerVersion") {
onError = CustomKotlinClosure1<Exception?, Unit> ({
if (this == null) {
// TODO: Fix after this is resolved: https://github.com/bmuschko/gradle-docker-plugin/issues/490
return@CustomKotlinClosure1 Unit
}
val message = "Docker is not installed or is not running."
if (skipDocker) {
logger.error("$message Skipping Docker dependent tasks.")
} else {
throw GradleException("$message To skip Docker tasks run with -P$skipDockerPropertyName flag.")
}
})
}
val pullRabbitmqContainer = task<DockerPullImage>("pullRabbitmq") {
tag = "latest"
repository = "rabbitmq"
dependsOn(getDockerVersion)
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val createRabbitmqContainer = task<DockerCreateContainer>("createRabbitmq") {
dependsOn(pullRabbitmqContainer)
portBindings = listOf("5672:5672")
targetImageId {
pullRabbitmqContainer.run { if (tag != null) "$repository:$tag" else repository }
}
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val startRabbitmqContainer = task<DockerStartContainer>("startRabbitmq") {
dependsOn(createRabbitmqContainer)
targetContainerId { createRabbitmqContainer.containerId }
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val removeRabbitmqContainer = task<DockerRemoveContainer>("removeRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
}
val stopRabbitmqContainer = task<DockerStopContainer>("stopRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
finalizedBy(removeRabbitmqContainer)
}
afterEvaluate {
tasks.getByName("junitPlatformTest") {
dependsOn(startRabbitmqContainer)
finalizedBy(stopRabbitmqContainer)
skipIfSkipDockerSpecified()
}
}
java.lang.IllegalArgumentException: Unsupported declaration type: VALUE_PARAMETER File name: MessageBroker.gradle.kts Physical: true Injected: false
buildscript {
dependencies {
classpath("com.bmuschko:gradle-docker-plugin:${property("gradle_docker_plugin.version")}")
}
}
apply {
plugin("com.bmuschko.docker-remote-api")
}
description = """
Manages all configuration and communication with the message broker.
""".trimMargin()
dependencies {
compile(group = "com.rabbitmq", name = "amqp-client", version = "4.1.0")
compile(group = "net.jodah", name = "failsafe", version = "1.0.4")
compile(group = "com.natpryce", name = "konfig", version = "1.6.1.0")
compile(group = "io.github.microutils", name = "kotlin-logging", version = "1.4.4")
compile(project(":DependencyInjection"))
}
fun isPortInUse(hostName : String, portNumber : Int) = try {
Socket(hostName, portNumber).close()
true
} catch (<caret>exception : Exception) {
false
}
val isRabbitmqRunning = isPortInUse("localhost", 5672)
fun Task.skipIfRabbitmqRunning() {
onlyIf {
!isRabbitmqRunning
}
}
/**
* Workaround for:
* - https://github.com/gradle/kotlin-dsl/issues/593
* - https://github.com/bmuschko/gradle-docker-plugin/issues/495
*/
class CustomKotlinClosure1<in T : Any?, V : Any>(
val function: T.() -> V?,
owner: Any? = null,
thisObject: Any? = null) : groovy.lang.Closure<V?>(owner, thisObject) {
@Suppress("unused") // to be called dynamically by Groovy
fun doCall(it: T): V? = it.function()
}
/*
* We want to make it possible to run the build without docker installed.
* We do so by adding the ability to specify a `-PskipDocker` or `-PskipDocker=true` flag when executing gradle.
* When specified this will skip the docker tasks and will not run any tasks dependent upon Docker running.
*/
val skipDockerPropertyName = "skipDocker"
val skipDocker = hasProperty(skipDockerPropertyName) && property(skipDockerPropertyName) != "false"
fun Task.skipIfSkipDockerSpecified() {
onlyIf { !skipDocker }
}
val getDockerVersion = task<DockerVersion>("getDockerVersion") {
onError = CustomKotlinClosure1<Exception?, Unit> ({
if (this == null) {
// TODO: Fix after this is resolved: https://github.com/bmuschko/gradle-docker-plugin/issues/490
return@CustomKotlinClosure1 Unit
}
val message = "Docker is not installed or is not running."
if (skipDocker) {
logger.error("$message Skipping Docker dependent tasks.")
} else {
throw GradleException("$message To skip Docker tasks run with -P$skipDockerPropertyName flag.")
}
})
}
val pullRabbitmqContainer = task<DockerPullImage>("pullRabbitmq") {
tag = "latest"
repository = "rabbitmq"
dependsOn(getDockerVersion)
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val createRabbitmqContainer = task<DockerCreateContainer>("createRabbitmq") {
dependsOn(pullRabbitmqContainer)
portBindings = listOf("5672:5672")
targetImageId {
pullRabbitmqContainer.run { if (tag != null) "$repository:$tag" else repository }
}
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val startRabbitmqContainer = task<DockerStartContainer>("startRabbitmq") {
dependsOn(createRabbitmqContainer)
targetContainerId { createRabbitmqContainer.containerId }
skipIfRabbitmqRunning()
skipIfSkipDockerSpecified()
}
val removeRabbitmqContainer = task<DockerRemoveContainer>("removeRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
}
val stopRabbitmqContainer = task<DockerStopContainer>("stopRabbitmq") {
onlyIf { createRabbitmqContainer.containerId != null }
targetContainerId { createRabbitmqContainer.containerId }
finalizedBy(removeRabbitmqContainer)
}
afterEvaluate {
tasks.getByName("junitPlatformTest") {
dependsOn(startRabbitmqContainer)
finalizedBy(stopRabbitmqContainer)
skipIfSkipDockerSpecified()
}
}
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver$resolveToDescriptor$1.visitKtElement(LazyDeclarationResolver.kt:205)
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver$resolveToDescriptor$1.visitKtElement(LazyDeclarationResolver.kt:94)
at org.jetbrains.kotlin.psi.KtVisitor.visitExpression(KtVisitor.java:182)
at org.jetbrains.kotlin.psi.KtVisitor.visitDeclaration(KtVisitor.java:29)
at org.jetbrains.kotlin.psi.KtVisitor.visitNamedDeclaration(KtVisitor.java:398)
at org.jetbrains.kotlin.psi.KtVisitor.visitParameter(KtVisitor.java:138)
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver$resolveToDescriptor$1.visitParameter(LazyDeclarationResolver.kt:163)
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver$resolveToDescriptor$1.visitParameter(LazyDeclarationResolver.kt:94)
at org.jetbrains.kotlin.psi.KtParameter.accept(KtParameter.java:50)
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver.resolveToDescriptor(LazyDeclarationResolver.kt:94)
at org.jetbrains.kotlin.resolve.lazy.LazyDeclarationResolver.resolveToDescriptor(LazyDeclarationResolver.kt:91)
at org.jetbrains.kotlin.resolve.lazy.ResolveSession.resolveToDescriptor(ResolveSession.java:331)
at org.jetbrains.kotlin.idea.project.ResolveElementCache.resolveToElements(ResolveElementCache.kt:216)
at org.jetbrains.kotlin.idea.caches.resolve.ResolutionFacadeImpl.analyze(ResolutionFacadeImpl.kt:59)
at org.jetbrains.kotlin.idea.caches.resolve.ResolutionFacadeImpl.analyze(ResolutionFacadeImpl.kt:53)
at org.jetbrains.kotlin.idea.caches.resolve.ResolutionUtils.analyze(resolutionApi.kt:82)
at org.jetbrains.kotlin.idea.caches.resolve.ResolutionUtils.resolveToDescriptorIfAny(resolutionApi.kt:61)
at org.jetbrains.kotlin.idea.caches.resolve.ResolutionUtils.resolveToDescriptorIfAny$default(resolutionApi.kt:59)
at org.jetbrains.kotlin.idea.inspections.OverridingDeprecatedMemberInspection$buildVisitor$1.registerProblemIfNeeded(OverridingDeprecatedMemberInspection.kt:46)
at org.jetbrains.kotlin.idea.inspections.OverridingDeprecatedMemberInspection$buildVisitor$1.visitNamedDeclaration(OverridingDeprecatedMemberInspection.kt:38)
at org.jetbrains.kotlin.psi.KtVisitorVoid.visitNamedDeclaration(KtVisitorVoid.java:959)
at org.jetbrains.kotlin.psi.KtVisitorVoid.visitNamedDeclaration(KtVisitorVoid.java:21)
at org.jetbrains.kotlin.psi.KtVisitor.visitParameter(KtVisitor.java:138)
at org.jetbrains.kotlin.psi.KtVisitorVoid.visitParameter(KtVisitorVoid.java:125)
at org.jetbrains.kotlin.psi.KtVisitorVoid.visitParameter(KtVisitorVoid.java:591)
at org.jetbrains.kotlin.psi.KtVisitorVoid.visitParameter(KtVisitorVoid.java:21)
at org.jetbrains.kotlin.psi.KtParameter.accept(KtParameter.java:50)
at org.jetbrains.kotlin.psi.KtElementImplStub.accept(KtElementImplStub.java:58)
at com.intellij.codeInspection.InspectionEngine.acceptElements(InspectionEngine.java:82)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.a(LocalInspectionsPass.java:305)
at com.intellij.concurrency.ApplierCompleter.c(ApplierCompleter.java:133)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1142)
at com.intellij.concurrency.ApplierCompleter.a(ApplierCompleter.java:105)
at com.intellij.openapi.progress.impl.CoreProgressManager.a(CoreProgressManager.java:548)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:493)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:94)
at com.intellij.concurrency.ApplierCompleter.b(ApplierCompleter.java:116)
at com.intellij.concurrency.ApplierCompleter.a(ApplierCompleter.java:96)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:142)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:237)
at com.intellij.concurrency.ApplierCompleter.compute(ApplierCompleter.java:96)
at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at java.util.concurrent.ForkJoinPool$WorkQueue.pollAndExecCC(ForkJoinPool.java:1190)
at java.util.concurrent.ForkJoinPool.helpComplete(ForkJoinPool.java:1879)
at java.util.concurrent.ForkJoinPool.awaitJoin(ForkJoinPool.java:2045)
at java.util.concurrent.ForkJoinTask.doJoin(ForkJoinTask.java:390)
at java.util.concurrent.ForkJoinTask.join(ForkJoinTask.java:719)
at java.util.concurrent.ForkJoinPool.invoke(ForkJoinPool.java:2616)
at com.intellij.concurrency.JobLauncherImpl.invokeConcurrentlyUnderProgress(JobLauncherImpl.java:63)
at com.intellij.concurrency.JobLauncher.invokeConcurrentlyUnderProgress(JobLauncher.java:57)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.a(LocalInspectionsPass.java:316)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.a(LocalInspectionsPass.java:226)
at com.intellij.codeInsight.daemon.impl.LocalInspectionsPass.collectInformationWithProgress(LocalInspectionsPass.java:132)
at com.intellij.codeInsight.daemon.impl.ProgressableTextEditorHighlightingPass.doCollectInformation(ProgressableTextEditorHighlightingPass.java:83)
at com.intellij.codeHighlighting.TextEditorHighlightingPass.collectInformation(TextEditorHighlightingPass.java:70)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.c(PassExecutorService.java:438)
at com.intellij.openapi.application.impl.ApplicationImpl.tryRunReadAction(ApplicationImpl.java:1148)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.d(PassExecutorService.java:431)
at com.intellij.openapi.progress.impl.CoreProgressManager.a(CoreProgressManager.java:548)
at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:493)
at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:94)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.a(PassExecutorService.java:430)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.b(PassExecutorService.java:406)
at com.intellij.openapi.application.impl.ReadMostlyRWLock.executeByImpatientReader(ReadMostlyRWLock.java:142)
at com.intellij.openapi.application.impl.ApplicationImpl.executeByImpatientReader(ApplicationImpl.java:237)
at com.intellij.codeInsight.daemon.impl.PassExecutorService$ScheduledPass.run(PassExecutorService.java:404)
at com.intellij.concurrency.JobLauncherImpl$VoidForkJoinTask$1.exec(JobLauncherImpl.java:165)
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157)
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - IntelliJ IDEA 2017.2.5 Build #IU-172.4343.14
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - JDK: 1.8.0_152-release
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - VM: OpenJDK 64-Bit Server VM
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - Vendor: JetBrains s.r.o
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - OS: Mac OS X
2017-11-17 16:37:29,959 [179662370] ERROR - aemon.impl.PassExecutorService - Last Action: ExternalSystem.RefreshAllProjects
Steps to Reproduce (for bugs)
Your Environment
------------------------------------------------------------
Gradle 4.3.1
------------------------------------------------------------
Build time: 2017-11-08 08:59:45 UTC
Revision: e4f4804807ef7c2829da51877861ff06e07e006d
Groovy: 2.4.12
Ant: Apache Ant(TM) version 1.9.6 compiled on June 29 2015
JVM: 1.8.0_92 (Oracle Corporation 25.92-b14)
OS: Mac OS X 10.12.6 x86_64
IntelliJ Kotlin Plugin version 1.1.60-release-IJ2017.2-1
I was running a much older version of the plugin and I was still seeing the problem then as well.
Hey @JLLeitschuh, could you try this again with the Kotlin 1.2 IntelliJ plugin and the latest distribution snapshot (which includes Kotlin 1.2):
./gradlew wrapper --gradle-distribution-url https://repo.gradle.org/gradle/dist-snapshots/gradle-kotlin-dsl-4.5-20171129024112+0000-all.zip
Will give this a shot, yes.
@JLLeitschuh could you get back to us with your findings on this issue using the Kotlin 1.2 toolchain?
@eskatos I'm still seeing exactly the same problem in the IntelliJ logs.
Versions:
------------------------------------------------------------
Gradle 4.3.1
------------------------------------------------------------
Build time: 2017-11-08 08:59:45 UTC
Revision: e4f4804807ef7c2829da51877861ff06e07e006d
Groovy: 2.4.12
Ant: Apache Ant(TM) version 1.9.6 compiled on June 29 2015
JVM: 1.8.0_92 (Oracle Corporation 25.92-b14)
OS: Mac OS X 10.13.2 x86_64
Other Versions:
IntelliJ IDEA 2017.3.1 (Ultimate Edition)
Build #IU-173.3942.27, built on December 11, 2017
Licensed to Plexxi, Inc. / Jonathan Leitschuh
You have a perpetual fallback license for this version
Subscription is active until December 14, 2018
JRE: 1.8.0_152-release-1024-b8 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Mac OS X 10.13.2
IntelliJ Kotlin Plugin Version:
1.2.0-release-IJ2017.3-1
Still seeing with:
1.2.20-release-IJ2017.3-1
Issue still exists with this version combo:
------------------------------------------------------------
Gradle 4.4.1
------------------------------------------------------------
Build time: 2017-12-20 15:45:23 UTC
Revision: 10ed9dc355dc39f6307cc98fbd8cea314bdd381c
Groovy: 2.4.12
Ant: Apache Ant(TM) version 1.9.9 compiled on February 2 2017
JVM: 1.8.0_92 (Oracle Corporation 25.92-b14)
OS: Mac OS X 10.13.2 x86_64
IntelliJ Kotlin Plugin Version:
1.2.20-release-IJ2017.3-1
Gradle 4.4.1 comes with Gradle Kotlin DSL 0.13.2 that brings Kotlin 1.1.51.
Could you try again with Gradle 4.5-rc-2?
I am getting the same issue. Gradle 4.6, Kotlin 1.2.31, Intellij 2018.1 (community) Kotlin plugin 1.2.31-2018.1. JDK: 1.8.0_152
Since upgrading from IntelliJ Kotlin Plugin 1.2.30-2018.1, Intellij Inspections hang on all Kotlin files now, not just Gradle Kotlin DSL, so I wonder if this is more to do with the IntelliJ Kotlin plugin and not so much with the Gradle Kotlin DSL? (IntelliJ is now basically unusable for Kotlin development.)