Tim Schraepen
07/18/2022, 6:27 PMCannot access class 'io.ktor.util.pipeline.PipelineContext'. Check your module classpath for missing or conflicting dependencies
On these lines:
//file:Server.kt
fun main() {
embeddedServer(Netty, 9090) {
routing {
get("/hello") {
this // <- does not compile
// call.respondText("Hello world") // <- does not compile either
}
}
}.start(wait = true)
}
The Gradle build works fine.
Seems like it's an issue where the modules have separate dependencies, but IntelliJ doesn't make the distinction (loads everything on to the classpath) which ends up in conflicting dependencies.
I've got Java 11 as the Project SDK (but neither 8 nor 17 don't work either), and I've got the latest Kotlin version (currently 221-1.7.10-release-333-IJ5591.52)