Just tried making a new Ktor project w/ the IDEA p...
# ktor
d
Just tried making a new Ktor project w/ the IDEA plugin and got this error:
Copy code
Error:Kotlin: [Internal Error] java.lang.IllegalStateException: The provided plugin org.jetbrains.kotlin.scripting.compiler.plugin.ScriptingCompilerConfigurationComponentRegistrar is not compatible with this version of compiler
	at org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment.<init>(KotlinCoreEnvironment.kt:186)
	at org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment.<init>(KotlinCoreEnvironment.kt:119)
	at org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment$Companion.createForProduction(KotlinCoreEnvironment.kt:418)
	at org.jetbrains.kotlin.cli.jvm.K2JVMCompiler.createCoreEnvironment(K2JVMCompiler.kt:265)
	at org.jetbrains.kotlin.cli.jvm.K2JVMCompiler.doExecute(K2JVMCompiler.kt:154)
	at org.jetbrains.kotlin.cli.jvm.K2JVMCompiler.doExecute(K2JVMCompiler.kt:63)
	at org.jetbrains.kotlin.cli.common.CLICompiler.execImpl(CLICompiler.java:107)
	at org.jetbrains.kotlin.cli.common.CLICompiler.execImpl(CLICompiler.java:51)
	at org.jetbrains.kotlin.cli.common.CLITool.exec(CLITool.kt:96)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl$compile$$inlined$ifAlive$lambda$1.invoke(CompileServiceImpl.kt:399)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl$compile$$inlined$ifAlive$lambda$1.invoke(CompileServiceImpl.kt:98)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl$doCompile$$inlined$ifAlive$lambda$2.invoke(CompileServiceImpl.kt:920)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl$doCompile$$inlined$ifAlive$lambda$2.invoke(CompileServiceImpl.kt:98)
	at org.jetbrains.kotlin.daemon.common.DummyProfiler.withMeasure(PerfUtils.kt:137)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl.checkedCompile(CompileServiceImpl.kt:950)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl.doCompile(CompileServiceImpl.kt:919)
	at org.jetbrains.kotlin.daemon.CompileServiceImpl.compile(CompileServiceImpl.kt:397)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:357)
	at sun.rmi.transport.Transport$1.run(Transport.java:200)
	at sun.rmi.transport.Transport$1.run(Transport.java:197)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
	at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:573)
	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:835)
	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:688)
	at java.security.AccessController.doPrivileged(Native Method)
	at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:687)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.AbstractMethodError: org.jetbrains.kotlin.scripting.compiler.plugin.ScriptingCompilerConfigurationComponentRegistrar.registerProjectComponents(Lcom/intellij/mock/MockProject;Lorg/jetbrains/kotlin/config/CompilerConfiguration;)V
	at org.jetbrains.kotlin.cli.jvm.compiler.KotlinCoreEnvironment.<init>(KotlinCoreEnvironment.kt:184)
	... 33 more
?
d
Have you sdkman installed?
d
sdkman?
d
I had the same issue again after updating sdk
sdk
command in terminal prints something?
d
nope
d
are you using kotlin 1.2.50?
d
just sdk not found
yes
at least the idea plugin
d
sadly there is a known issue
try to change the gradle version to 1.2.41
or 1.2.51 grabbed from bintray
d
what's the repo name for 1.2.51?
d
maven { url { <http://dl.bintray.com/kotlin/kotlin-dev/> } }
d
It might be worth doing that by default for the ktor plugin?
d
actually I hope 1.2.51 gets released soon, then I will update the plugin to 1.2.51
plugins usually take from 1 to 2 working days to be updated
so maybe when it gets released there is 1.2.51 available
d
Also, it might be nice to put the make w/ plugin button in the site's gen form at the top of the page... I filled out the form, clicked that button, only to realize there's an idea plugin to do the same thing... then I filled the idea form... also tooltips in the idea form might be nice...
d
what would you put in the tooltips?
d
The text in the generator on the site describing each option
How do I update the idea plugin to 1.2.51? Just updating the gradle doesn't do it...
d
updating build.gradle and refreshing the gradle project
d
d
you have to add
maven { url { <http://dl.bintray.com/kotlin/kotlin-dev/> } }
in two places
the buildscript repositorioes, and top-level repositories
d
CONFIGURE FAILED in 0s Could not find method maven() for arguments [build_9myxp1p4o1ql7qxhh42vfgi6j$_run_closure1$_closure3$_closure4@5bcfe6b] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler. Open File
Could not find method maven() for arguments [build_9myxp1p4o1ql7qxhh42vfgi6j$_run_closure1$_closure3$_closure4@5bcfe6b] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
d
(trying)
Copy code
repositories {
	jcenter()
	maven { url '<https://kotlin.bintray.com/ktor>' }
	maven { url '<http://dl.bintray.com/kotlin/kotlin-eap/>' }
	maven { url '<http://dl.bintray.com/kotlin/kotlin-dev/>' }
}
try this block
copy it twice
and try again
it worked for me
d
nope...
d
in the case someone has the same problem, there is a kotlin plugin update for intelliJ:
1.2.50-release-IJ2018.1-1