Skip to content

Kotlin nightlies #6000

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

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@ env:

jobs:
benchmarks:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
2 changes: 1 addition & 1 deletion .github/workflows/bump-kotlin-nightlies.yml
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@ on:

jobs:
push-kotlin-nightlies-branch:
runs-on: macos-14
runs-on: macos-15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
with:
2 changes: 1 addition & 1 deletion .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@ on:

jobs:
nightly:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- run: |
2 changes: 1 addition & 1 deletion .github/workflows/platform-api-tests.yml
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@ env:

jobs:
platform-api-tests:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- name: Checkout project
8 changes: 4 additions & 4 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -18,7 +18,7 @@ concurrency:
jobs:
tests-gradle:
if: "!startsWith(github.head_ref, 'release-')"
runs-on: macos-14
runs-on: macos-15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
- uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 #v4.2.1
@@ -42,7 +42,7 @@ jobs:

tests-no-gradle:
if: "!startsWith(github.head_ref, 'release-')"
runs-on: macos-14
runs-on: macos-15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
- uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 #v4.2.1
@@ -66,7 +66,7 @@ jobs:

tests-integration:
if: "!startsWith(github.head_ref, 'release-')"
runs-on: macos-14
runs-on: macos-15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
- uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 #v4.2.1
@@ -88,7 +88,7 @@ jobs:
name: tests-integration.zip
path: diagnostics.zip
ios-tests:
runs-on: macos-14
runs-on: macos-15
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
- uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 #v4.2.1
2 changes: 1 addition & 1 deletion .github/workflows/preview.yml
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@ on:
type: string
jobs:
preview:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 #v4.2.1
2 changes: 1 addition & 1 deletion .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ env:

jobs:
deploy:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
2 changes: 1 addition & 1 deletion .github/workflows/tag.yml
Original file line number Diff line number Diff line change
@@ -10,7 +10,7 @@ env:
jobs:
publish-libraries:
name: Publish libraries
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
8 changes: 4 additions & 4 deletions build-logic/src/main/kotlin/CompilerOptions.kt
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@

import com.android.build.gradle.BaseExtension
import compat.patrouille.configureJavaCompatibility
import compat.patrouille.configureKotlinCompatibility
import org.gradle.api.JavaVersion
import org.gradle.api.Project
import org.gradle.api.plugins.JavaPluginExtension
import org.gradle.api.tasks.compile.JavaCompile
import org.gradle.api.tasks.testing.Test
import org.gradle.jvm.toolchain.JavaLanguageVersion
import org.gradle.jvm.toolchain.JavaToolchainService
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
import org.jetbrains.kotlin.gradle.dsl.KotlinAndroidProjectExtension
import org.jetbrains.kotlin.gradle.dsl.KotlinCommonCompilerOptions
import org.jetbrains.kotlin.gradle.dsl.KotlinJsCompilerOptions
@@ -28,6 +25,9 @@ fun KotlinCommonCompilerOptions.configure(
) {
freeCompilerArgs.add("-Xexpect-actual-classes")

// Suppress "Language version 1.9 is deprecated and its support will be removed in a future version of Kotlin"
freeCompilerArgs.add("-Xsuppress-version-warnings")

optIns.forEach {
freeCompilerArgs.add("-opt-in=$it")
}
6 changes: 3 additions & 3 deletions gradle/libraries.toml
Original file line number Diff line number Diff line change
@@ -28,12 +28,12 @@ javaPoet = "1.13.0"
jetbrains-annotations = "24.0.1"
junit = "4.13.2"
kotlin-plugin-min = "1.9.0"
kotlin-plugin = "2.1.20"
kotlin-plugin-max = "2.1.20"
kotlin-plugin = "2.2.0-dev-16956"
kotlin-plugin-max = "2.2.0-dev-16956"
kotlinx-coroutines = "1.9.0"
kotlinx-datetime = "0.5.0"
kotlinx-serialization-runtime = "1.6.2"
ksp = "2.1.20-2.0.0"
ksp = "2.2.0-Beta1-2.0.0"
ktor = "3.1.2"
moshix = "0.14.1"
node-fetch = "2.7.0"
4 changes: 2 additions & 2 deletions gradle/repositories.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
listOf(pluginManagement.repositories, dependencyResolutionManagement.repositories).forEach {
it.apply {
// Uncomment this one to use the Kotlin "dev" repository
// maven("https://redirector.kotlinlang.org/maven/dev/")
maven("https://redirector.kotlinlang.org/maven/dev/")
// Uncomment this one to use the Sonatype OSSRH snapshots repository
// maven("https://oss.sonatype.org/content/repositories/snapshots/")
maven("https://oss.sonatype.org/content/repositories/snapshots/")
// Uncomment this one to use the GradleUp repository
// maven("https://storage.googleapis.com/gradleup/m2")

4 changes: 2 additions & 2 deletions intellij-plugin/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -28,9 +28,9 @@ commonSetup()
// XXX: this should use the settings repositories instead
repositories {
// Uncomment this one to use the Kotlin "dev" repository
// maven("https://redirector.kotlinlang.org/maven/dev/")
maven("https://redirector.kotlinlang.org/maven/dev/")
// Uncomment this one to use the Sonatype OSSRH snapshots repository
// maven("https://oss.sonatype.org/content/repositories/snapshots/")
maven("https://oss.sonatype.org/content/repositories/snapshots/")
mavenCentral()

intellijPlatform {
Original file line number Diff line number Diff line change
@@ -23,7 +23,7 @@ repositories {
}
mavenCentral()
// Uncomment this one to use the Kotlin "dev" repository
// maven("https://redirector.kotlinlang.org/maven/dev/")
maven("https://redirector.kotlinlang.org/maven/dev/")
}

configure<ApolloExtension> {
Original file line number Diff line number Diff line change
@@ -7,12 +7,11 @@ import platform.Network.nw_path_monitor_set_queue
import platform.Network.nw_path_monitor_set_update_handler
import platform.Network.nw_path_monitor_start
import platform.Network.nw_path_monitor_t
import platform.Network.nw_path_monitor_update_handler_t
import platform.Network.nw_path_status_satisfied
import platform.Network.nw_path_t
import platform.darwin.dispatch_queue_create

internal class AppleNetworkObserver: NetworkObserver, nw_path_monitor_update_handler_t {
internal class AppleNetworkObserver: NetworkObserver, ((nw_path_t) -> Unit) {
var monitor: nw_path_monitor_t = null
var listener: NetworkObserver.Listener? = null

@@ -36,4 +35,4 @@ internal class AppleNetworkObserver: NetworkObserver, nw_path_monitor_update_han
override fun invoke(p1: nw_path_t) {
listener?.networkChanged((nw_path_get_status(p1) == nw_path_status_satisfied))
}
}
}
3 changes: 3 additions & 0 deletions tests/enums/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -47,5 +47,8 @@ tasks.withType(KotlinCompilationTask::class.java).configureEach {
compilerOptions {
apiVersion.set(KotlinVersion.KOTLIN_1_9)
languageVersion.set(KotlinVersion.KOTLIN_1_9)

// Suppress "Language version 1.9 is deprecated and its support will be removed in a future version of Kotlin"
freeCompilerArgs.add("-Xsuppress-version-warnings")
}
}
6 changes: 3 additions & 3 deletions tests/jsexport/src/jsTest/kotlin/JsExportTest.js.kt
Original file line number Diff line number Diff line change
@@ -23,9 +23,9 @@ actual val parserFactory: SubscriptionParserFactory?
object JsSubscriptionParserFactory : SubscriptionParserFactory {
override fun <D : Operation.Data> createParser(request: ApolloRequest<D>): SubscriptionParser<D> {
return object : SubscriptionParser<D> {
override fun parse(payload: ApolloJsonElement): ApolloResponse<D> {
override fun parse(response: ApolloJsonElement): ApolloResponse<D> {
return ApolloResponse.Builder(request.operation, request.requestUuid)
.data(payload.asDynamic().data.unsafeCast<D>())
.data(response.asDynamic().data.unsafeCast<D>())
.errors(null) // TODO: Error doesn't use @JsExport
.build()
}
@@ -87,4 +87,4 @@ object JsWsProtocol : WsProtocol {
else -> ParseErrorServerMessage("Unknown type: '$type' found in server message: '$text'")
}
}
}
}
Loading