how do i track down what causes ```Conflicting app...
# ktor
n
how do i track down what causes
Copy code
Conflicting application feature is already installed with the same key as `Default Headers`
? this happens on the first line in my ktor
application
block, definitly not duplicate registration in the code seems like koin 3.0.2 pulls in kotlin 1.5.0 which messes up the classpath and confuses ktor rolling that back fixed it for a while.. for some reason these settings have a impact.. especially language and api version
Copy code
tasks.withType<KotlinCompile> {
    kotlinOptions {
        apiVersion = "1.3"
        languageVersion = "1.3"
        jvmTarget = "1.8" // TODO: install newer java and use JAVA 15/16
    }
}
once i set it to language/api level
1.4
it triggers the error on startup
a
Please file an issue here with a sample project attached to reproduce your problem.
n
i tracked it down to using
Copy code
install(CORS) {
    maxAgeDuration = 12.toDuration(DurationUnit.HOURS)
    anyHost()
}
when
languageLevel
is set to 1.3 or 1.5 it works fine, but when it is set to 1.4 it causes the ktor app to reload at this point and feature before this get installed twice.. which leads to a error
not sure if that is worth reporting.. as its easy enough to set the languageLevel to 1.5 even when still using 1.4 and that fixes it
or setting
maxAgeInSeconds
instead