-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Kotlin to version 2.1.10 #45470
base: main
Are you sure you want to change the base?
Update Kotlin to version 2.1.10 #45470
Conversation
This comment has been minimized.
This comment has been minimized.
🎊 PR Preview 83338cf has been successfully built and deployed to https://quarkus-pr-main-45470-preview.surge.sh/version/main/guides/
|
This comment has been minimized.
This comment has been minimized.
1a6607a
to
16568be
Compare
I see the quickstarts compilation failed. I had a look at a problematic project and noticed that it has Kotlin version 1.7.20 set in its pom: https://github.com/quarkusio/quarkus-quickstarts/blob/main/hibernate-orm-panache-kotlin-quickstart/pom.xml Why is there a specific version set? Should it use the version comping from the platform bom? Can I update that quickstart to use Kotlin 2.1? |
There is also a failure in the Gradle tests. I'm not sure if I understand this test correctly, but it looks like it might use old Quarkus libraries compiled without the changes in this PR. Is this possible? Or am I misunderstanding this? The shows:
|
Which specific Gradle test is failing? |
It's |
You lost some of the additional changes I made in the operation. I added a commit restoring them. |
That being said, I'm unsure how it will fly with Gradle as I ended up having issues with Gradle compatibility itself. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
I've created quarkusio/quarkus-quickstarts#1489 to update the Quickstart to fix that build error. Unfortunately, I don't understand the other compilation errors. Are they just flaky tests or is there something I need to fix? I'm a bit confused... |
Yeah so the remaining error is the one for which I was thinking we would need a Gradle upgrade to be compatible but I'm not entirely sure:
I think you will need to have a look at what this method is and why it can't find it. |
This might be caused by https://youtrack.jetbrains.com/issue/KTIJ-31860/Sync-failure-when-using-Kotlin-2.1.20-dev-1129 |
@gsmet : How did you find this exception? I tried to look in the raw logs of the failed builds, but couldn't find it. |
There is a link to a Gradle build scan. I just searched for the module name and loaded the build scan. |
e610fe7
to
ca6c032
Compare
So from what I found, it seems Gradle moved/renamed a class (remvoing To reproduce this issue, the simplest way is to switch into the directory Maybe a gradle expert has an idea? |
I think we will just have to wait for a new version of Gradle compatible with Kotlin 2.1.0. |
Probably related to gradle/gradle#31549 |
@andreas-eberle maybe this is the missing piece: #45899 |
thanks! I will have a look. |
03024ab
to
3e4f929
Compare
I have quickly updated the dependencies but couldn't test it locally yet. Maybe on Thursday I can check it locally. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Any news? |
My understanding is that we need a Gradle version compatible with Kotlin 2.1.10 and we're not there yet but I would be happy to get corrected. |
Thanks @gsmet .This would mean that a downgrade of the Gradle version should solve the problem. BTW The upcoming Kotlin 2.1.20 has full featue support for Gradle 8.11 (https://kotlinlang.org/docs/whatsnew-eap.html#gradle-support-for-version-8-11) |
I dunno. I'm not sure we actually understood the issue as they say it's compatible and we have a method not found exception (or something similar). I don't have the cycles to get to the bottom of it tbh so if you want to experiment, feel free to do so. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the kotlin maven plugin used here versioned by the BOM or a parent pom?
3e4f929
to
48f5cc3
Compare
I realized that gradle does not support Kotlin 2.1 for it's plugins yet, but we can use it for the we build nonetheless. Therefore I reverted the Gradle Plugin Kotlin Version again to 2.0.21 and locally that fixed the build of the gradle plugin. I pushed the changes, to see if the rest works out. Locally I always run into some failing tests on my Windows machine and thus can never complete the full build. |
It’s nice if it fixed the build but what about the generated projects? |
What do you mean? Can you elaborate? |
Update Kotlin to version 2.1.0, Kotlinx Serialization to 1.8.0 and Kotlin Coroutines to 1.10.0
Since the Kotlin update was removed again from PR #45228, I'm opening this PR to add it separately. This is an updated version of the original PR #44809.