From 28e4bc48dd6230eb21127808e0fe5f866f1869a9 Mon Sep 17 00:00:00 2001 From: Luna712 <142361265+Luna712@users.noreply.github.com> Date: Wed, 3 Jun 2026 10:11:18 -0600 Subject: [PATCH] Update Kotlin to 2.4.0 * Uuid is now stable, so remove opt-in * `annotation-default-target=param-property` is now default, and compiler warns about it being redundant, so remove * Compiler now warns about a redundant expression in HomeFragment, so just remove redundant `true`; has no other affect --- app/build.gradle.kts | 2 -- .../java/com/lagradost/cloudstream3/ui/home/HomeFragment.kt | 1 - gradle/libs.versions.toml | 2 +- library/build.gradle.kts | 5 +---- .../kotlin/com/lagradost/cloudstream3/utils/ExtractorApi.kt | 3 --- 5 files changed, 2 insertions(+), 11 deletions(-) diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 6c784f3ef8d..8c169477496 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -313,11 +313,9 @@ tasks.withType { compilerOptions { jvmTarget.set(javaTarget) jvmDefault.set(JvmDefaultMode.ENABLE) - freeCompilerArgs.add("-Xannotation-default-target=param-property") optIn.addAll( "com.lagradost.cloudstream3.InternalAPI", "com.lagradost.cloudstream3.Prerelease", - "kotlin.uuid.ExperimentalUuidApi", ) } } diff --git a/app/src/main/java/com/lagradost/cloudstream3/ui/home/HomeFragment.kt b/app/src/main/java/com/lagradost/cloudstream3/ui/home/HomeFragment.kt index b68ef59625c..ab0715c6de3 100644 --- a/app/src/main/java/com/lagradost/cloudstream3/ui/home/HomeFragment.kt +++ b/app/src/main/java/com/lagradost/cloudstream3/ui/home/HomeFragment.kt @@ -665,7 +665,6 @@ class HomeFragment : BaseFragment( fromUI = true ) showToast(R.string.action_reload, Toast.LENGTH_SHORT) - true } homePreviewSearchButton.setOnClickListener { _ -> diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index b93c4474c23..7d3d2867134 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -26,7 +26,7 @@ junit = "4.13.2" junitKtx = "1.3.0" junitVersion = "1.3.0" juniversalchardet = "2.5.0" -kotlinGradlePlugin = "2.3.20" +kotlinGradlePlugin = "2.4.0" kotlinxAtomicfu = "0.33.0" kotlinxCollectionsImmutable = "0.4.0" kotlinxCoroutinesCore = "1.11.0" diff --git a/library/build.gradle.kts b/library/build.gradle.kts index 1652970a617..7c0b7d2c1b2 100644 --- a/library/build.gradle.kts +++ b/library/build.gradle.kts @@ -39,10 +39,7 @@ kotlin { jvm() compilerOptions { - freeCompilerArgs.addAll( - "-Xexpect-actual-classes", - "-Xannotation-default-target=param-property" - ) + freeCompilerArgs.add("-Xexpect-actual-classes") } sourceSets { diff --git a/library/src/commonMain/kotlin/com/lagradost/cloudstream3/utils/ExtractorApi.kt b/library/src/commonMain/kotlin/com/lagradost/cloudstream3/utils/ExtractorApi.kt index f42128b1013..39a2f4c44d7 100644 --- a/library/src/commonMain/kotlin/com/lagradost/cloudstream3/utils/ExtractorApi.kt +++ b/library/src/commonMain/kotlin/com/lagradost/cloudstream3/utils/ExtractorApi.kt @@ -1,5 +1,3 @@ -@file:OptIn(ExperimentalUuidApi::class) - package com.lagradost.cloudstream3.utils import com.fasterxml.jackson.annotation.JsonIgnore @@ -318,7 +316,6 @@ import kotlinx.coroutines.ensureActive import org.jsoup.Jsoup import java.net.URI import kotlin.coroutines.cancellation.CancellationException -import kotlin.uuid.ExperimentalUuidApi import kotlin.uuid.Uuid import kotlin.uuid.toJavaUuid import kotlin.uuid.toKotlinUuid