-
-
Notifications
You must be signed in to change notification settings - Fork 757
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 NoSuchMethodError when running with type resolution on Kotlin 1.8.0-Beta #5582
Comments
Please have a look at #5551 - I suspect the same root cause. |
This issues are more and more frequent... should our gradle plugin check for the version of the compiler that is in the classpath and fail with a descriptive message? It's not just to avoid the "noise" on the issue tracker (I'm not too much converned there) but to give a fast feedback to out users. |
It should, yes, but when I tried implementing a check it wasn't all that clean and I wasn't confident that it would be reliable. If someone wants to pick that up then please go ahead. |
I think that I might have hit this here: https://scans.gradle.com/s/2xqkokxu3nanc/failure#1 |
Yes, if you look at the Dependencies in the build scan, and drill down into the detekt configuration, you'll see the dependency version has been overridden. I'm going to close this, as there's a new issue to cover adding a warning, and this appears to be a support issue and not an issue with detekt itself. |
Expected Behavior
Running the
detektMain
Gradle task should complete without failures.Observed Behavior
A build with
detektMain
works fine with Kotlin 1.7.21, but fails with Kotlin 1.8.0-Beta.Using the
detekt
task works fine with both.Works with Kotlin 1.7.21:
Fails with Kotlin 1.8.0-Beta:
Steps to Reproduce
I tried to reproduce this from scratch with a couple of tiny projects created using
gradle init
, and added a method that triggeredIgnoredReturnValue
when runningdetektMain
, but I unfortunately couldn't reproduce this failure with Kotlin 1.8.0-Beta.However, hopefully someone has an idea of what the underlying cause might be here. Otherwise, I can try and reduce the existing project above down to something simpler and reproducible.
Context
I'm trying to use type resolution to get more thorough static analysis, but falling back to "regular" Detekt also isn't a huge deal.
Your Environment
The text was updated successfully, but these errors were encountered: