-
Notifications
You must be signed in to change notification settings - Fork 63
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
Kotlin K2 Support #546
Comments
I guess the mentioned flags are outdated, and they should be removed |
K2 is still in beta with the latest Kotlin release (1.9.22), isn't it. What if we use this issue to document the problems with K2 and the stuff that has to be changes, like dropping some compiler flags - and maybe adding others. BTW, @mgroth0 What's the correct way to use K2 from Gradle with the current Kotlin release? |
See https://kotlinlang.org/docs/whatsnew19.html#try-the-k2-compiler-in-your-project
|
Thanks @vlsi . |
The majority of compilation errors are caused by WDYT of completely removing |
I think you should be able to drop |
At least worth a try. |
Thank you both for looking into this and for giving K2 a shot. I've been working with K2 for a month or so now. It's still unstable, and I've had to create workarounds for many issues. Sorry for dumping this on you guys. It might be smart to wait a few more months at least. I expect Jetbrains will have resolved many more issues by then. |
jsr305 removal makes sense even without K2 |
Kotlin 2.0 has been released yesterday: https://kotlinlang.org/docs/whatsnew20.html |
That somehow strongly suggests to migrate to K2 with jqwik 1 rather sooner than later. I had hoped to defer that till version 2 :-/ |
Published in |
Could be just me, but it seems like -Xjsr305 property is still respected by the final version of the compiler. Also, just wanted to check if always targetting the latest version of kotlin is intended? I assume that regardless of how good Kotlin devs are, some may obstain from updating to it immediately. So maybe setting a kotlinTarget to 1.9 would be a good idea? |
Since jsr305 is no longer used this shouldn't affect jqwik's Kotlin module. But maybe I'm missing something. |
Frankly, I find the current state of how to set minimum and compilation versions of Kotlin in Gradle highly confusing. I just cannot find documentation that describes it sufficiently for me. Anyways, I tried to set min target version to 1.9 and released it as a snapshot (`1.9.0-SNAPSHOT'). See e5ac104. |
Testing Problem
I am testing with Kotlin K2 (Kotlin version 2.0.0-Beta2). I just discovered jqwik and wanted to play around with it and consider integrating it into my projects. The docs for kotlin say to include these compiler arguments:
I tried to add the two compiler arguments above, but then got the following warnings:
This signals to me that jqwik does not yet have first class support for Kotlin 2, so I am hesitating to use it for now.
Suggested Solution
I suggest to add support for Kotlin 2. The documentation could be updated to say how the user should configure kotlin if they use K2, which would also reasure the user that K2 is supported.
The text was updated successfully, but these errors were encountered: