I'm having trouble upgrading to kotlin 1.9.0 due to kotlinx-serialization. When I change the plugin ...
r

Rasmus

almost 2 years ago
I'm having trouble upgrading to kotlin 1.9.0 due to kotlinx-serialization. When I change the plugin version reference for kotlinx-serialization to 1.9.0 for some reason Gradle attempts to download plugin version 1.8.10 instead. This fails for some reason, but it looks like version 1.8.10 does exist 🤷‍♂️. We are using kotlinx-serialization 1.5.1 btw. My first thought was that there is some kind of cache issue, but I tried clearing everything. Besides, the previous version we used was version 1.8.21 which worked fine. We're using version catalog to define the plugin:
plugin("kotlin-serialization", "org.jetbrains.kotlin.plugin.serialization").version("1.9.0")
and alias to bring in the plugin:
alias(_libs_._plugins_._kotlin_._serialization_)
, if it's overridden with
.version("1.8.21")
the build succeeds, so I don't think it's related to how the plugin is loaded. This is the error output I get:
Execution failed for task ':core:compileKotlin'.
Could not resolve all files for configuration ':core:kotlinCompilerPluginClasspathMain'.
   > Could not find org.jetbrains.kotlin:kotlin-serialization-compiler-plugin-embeddable:1.8.10.
     Searched in the following locations:
       - <https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-serialization-compiler-plugin-embeddable/1.8.10/kotlin-serialization-compiler-plugin-embeddable-1.8.10.pom>
     If the artifact you are trying to retrieve can be found in the repository but without metadata in 'Maven POM' format, you need to adjust the 'metadataSources { ... }' of the repository declaration.
     Required by:
         project :core
Any ideas?