Skip to content

Update Kotlin to v1.8.0#5614

Merged
3flex merged 6 commits intomainfrom
kotlin-1.8
Dec 30, 2022
Merged

Update Kotlin to v1.8.0#5614
3flex merged 6 commits intomainfrom
kotlin-1.8

Conversation

@3flex
Copy link
Copy Markdown
Member

@3flex 3flex commented Dec 8, 2022

@github-actions github-actions Bot added the dependencies Pull requests that update a dependency file label Dec 8, 2022
@codecov
Copy link
Copy Markdown

codecov Bot commented Dec 8, 2022

Codecov Report

Merging #5614 (c56b9ab) into main (110c6f9) will not change coverage.
The diff coverage is n/a.

❗ Current head c56b9ab differs from pull request most recent head a62714b. Consider uploading reports for the commit a62714b to get more accurate results

@@     Coverage Diff      @@
##   main   #5614   +/-   ##
============================
============================

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@3flex
Copy link
Copy Markdown
Member Author

3flex commented Dec 8, 2022

💥

@3flex
Copy link
Copy Markdown
Member Author

3flex commented Dec 10, 2022

Blocked on tschuchortdev/kotlin-compile-testing#336

We might need to switch to running all tests via CLI and/or Gradle for the compiler plugin to avoid being continuously blocked by this dependency when Kotlin is updated. That dependency isn't updated frequently.

@3flex 3flex changed the title Smoke test Kotlin 1.8 Update Kotlin to v1.8.0 Dec 30, 2022
@3flex 3flex marked this pull request as ready for review December 30, 2022 00:46
@3flex 3flex added notable changes Marker for notable changes in the changelog and removed blocked labels Dec 30, 2022

tasks.test {
// https://github.com/detekt/detekt/issues/5646
enabled = false
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👀

@3flex 3flex merged commit a22d301 into main Dec 30, 2022
@3flex 3flex deleted the kotlin-1.8 branch December 30, 2022 10:52
atulgpt pushed a commit to atulgpt/detekt that referenced this pull request Dec 30, 2022
* Update Kotlin to v1.8.0

* Add required annotations for Kotlin 1.8

* Set IR backend mode explicitly in JS Gradle tests

This is the default backend from Kotlin 1.8 but an opt-in is required.

* Migrate from kotlinOptions to compilerOptions

https://kotlinlang.org/docs/whatsnew18.html#exposing-kotlin-compiler-options-as-gradle-lazy-properties

* Update list of compatible JVM targets

* Disable :detekt-compiler-plugin:test task
@tokuhirom
Copy link
Copy Markdown

Is there a plan to release new version includes this commit? I want to use detekt with kotlin-1.8.x

@3flex
Copy link
Copy Markdown
Member Author

3flex commented Mar 3, 2023

You can either:

  1. Use a snapshot version of detekt which has this commit included.
  2. Update your project to Kotlin 1.8 but use the existing detekt version. As long as you're not using any new Kotlin 1.8 language features this should work.

@eboudrant
Copy link
Copy Markdown

eboudrant commented Mar 7, 2023

Update your project to Kotlin 1.8 but use the existing detekt version. As long as you're not using any new Kotlin 1.8 language features this should work.

What do you mean by that? We updated to Kotlin 1.8.10 (along with Ksp 1.8.10-1.0.9, Compose Kotlin compiler 1.4.2, Detekt 1.22.0) but we still see the error, we're not using any new Kotlin 1.8 language features.

btw, using snapshots works.

@3flex
Copy link
Copy Markdown
Member Author

3flex commented Mar 7, 2023

we still see the error

What error do you see? Consider opening a new issue so we can assist.

@ravermeister
Copy link
Copy Markdown

ravermeister commented Mar 17, 2023

I have the same problem as described above, after trying to switch to kotlin 1.8 with same detekt version 1.22.0 I see:

* What went wrong:
Execution failed for task ':archiv-impl:detekt'.
> Analyzing /builds/path/to/sourceFolder/src/main/kotlin/de/company/package/info/CacheInfo.kt led to an exception.
  Location: io.gitlab.arturbosch.detekt.rules.bugs.ImplicitDefaultLocale.checkStringFormatting(ImplicitDefaultLocale.kt:70)
  The original exception message was: 'org.jetbrains.kotlin.psi.KtExpression org.jetbrains.kotlin.resolve.calls.util.CallUtilKt.getCalleeExpressionIfAny(org.jetbrains.kotlin.psi.KtElement)'
  Running detekt '1.22.0' on Java '17.0.6+10' on OS 'Linux'
  If the exception message does not help, please feel free to create an issue on our GitHub page.

@3flex
Copy link
Copy Markdown
Member Author

3flex commented Mar 17, 2023

Hi, please open a new issue for this, thanks!

@pexa-agopalakrishnan
Copy link
Copy Markdown

I have the same problem as described above, after trying to switch to kotlin 1.8 with same detekt version 1.22.0 I see:

* What went wrong:
Execution failed for task ':archiv-impl:detekt'.
> Analyzing /builds/path/to/sourceFolder/src/main/kotlin/de/company/package/info/CacheInfo.kt led to an exception.
  Location: io.gitlab.arturbosch.detekt.rules.bugs.ImplicitDefaultLocale.checkStringFormatting(ImplicitDefaultLocale.kt:70)
  The original exception message was: 'org.jetbrains.kotlin.psi.KtExpression org.jetbrains.kotlin.resolve.calls.util.CallUtilKt.getCalleeExpressionIfAny(org.jetbrains.kotlin.psi.KtElement)'
  Running detekt '1.22.0' on Java '17.0.6+10' on OS 'Linux'
  If the exception message does not help, please feel free to create an issue on our GitHub page.

yes, im also facing the same issue after upgrading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build cli dependencies Pull requests that update a dependency file gradle notable changes Marker for notable changes in the changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants