Closed exaV closed 1 week ago
This should be fixed by https://github.com/Kotlin/kotlin-jupyter/commit/d91d0a1b9151653a4ee2f9d8504a36a84644fb14
@cmelchior First of all thank you for taking the time to apply the fix. I just tried to test the latest release but I don't know how. When I create a kotlin-notebook in intellij it does not use the latest release of kotlin-jupyter right? Can I somehow tell to IDE to do that? Or do I have to wait for a plugin update?
Another question, I know it only loosely related, but maybe you can help point me in the right direction. I have the same issue with regular *.main.kts (kotlin script) files inside Intellij because intellij uses an embedded version of the compiler (version 1.9.x) to run script files. I have no idea where I can open an issue to ask for an upgrade or track progress on that work. I my PR I asked the same and was told it would arrive with Intellj 2024.2.x but it didn't and latest EAP does not have it either.
You can change the Kernel version in the Notebook settings (see attached screenshot). The version that was released with the fix is 0.12.0.331
main.kts
file support is part of the Kotlin Compiler itself. So if you are using Kotlin 2.0.20+, it should "just work".
But since, Kotlin is now bundled directly with the IDE, getting the right version can be a bit tricky as I don't think there is a way to change the Kotlin version independently.
From this list here: https://plugins.jetbrains.com/docs/intellij/using-kotlin.html#kotlin-standard-library Kotlin 2.0.21 should be bundled with 2024.3, but that hasn't been officially released yet. But if you use the 2024.3 EAP release, your fix should be included.
Thanks, that worked 👍
Yet another issue: when using %use kandy
I get an error like Could not find artifact org.jetbrains.kotlinx:kotlin-statistics-jvm:jar:0.3.1 in company-artifactory (https://internal-url...)
but it works fine with @file:DependsOn("org.jetbrains.kotlinx:kandy-lets-plot:0.7.1")
. Something like that could happen if those artifacts are not available in any of the repositories we have in our mirror (like maven-central), but that would not explain why it works with DependsOn
. Anyway we have a working solution now so thanks again.
And thanks for the hint with Intellij, after upgrading my eap version (I think I tried eap5 before) it finally works! 🚀
Could you please upgrade kotlinMavenResolver from 2.0.0-Beta5 to 2.0.20?
I submitted a fix for dependency resolution with (authenticated) maven mirrors here https://github.com/JetBrains/kotlin/commit/9c05493cb10be14305a409fa8d78810c9aea1612 which is present in 2.0.20. With the fix we would finally be able to use Kotlin notebooks in our corporate environment where we (must) use maven mirror for all requests.
The two commits from the fix are also the only changes between 2.0.0-Beta5 and 2.0.20, so it should be safe to upgrade.