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 7 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
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
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/bump-kotlin-nightlies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
nightly:
runs-on: macos-14
runs-on: macos-15
if: github.repository == 'apollographql/apollo-kotlin'
steps:
- run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/platform-api-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand All @@ -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
Expand All @@ -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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
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
Expand All @@ -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")
}
Expand Down
6 changes: 3 additions & 3 deletions gradle/libraries.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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-Beta2-2.0.1"
ktor = "3.1.2"
moshix = "0.14.1"
node-fetch = "2.7.0"
Expand Down
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")

Expand Down
4 changes: 2 additions & 2 deletions intellij-plugin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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

Expand All @@ -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
Expand Up @@ -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
Expand Up @@ -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()
}
Expand Down Expand Up @@ -87,4 +87,4 @@ object JsWsProtocol : WsProtocol {
else -> ParseErrorServerMessage("Unknown type: '$type' found in server message: '$text'")
}
}
}
}
Loading