-
Notifications
You must be signed in to change notification settings - Fork 0
Downgrade Kotlin to 2.1.21 #1
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -1,7 +1,8 @@ | ||||||
| # MCP Kotlin SDK | ||||||
|
|
||||||
| [](http://kotlinlang.org) | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Align Kotlin badge with actual version (2.1.21). Badge shows "2.1"; suggest "2.1.21" to match libs.versions.toml and avoid drift. -[](http://kotlinlang.org)
+[](http://kotlinlang.org)📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||
| [](https://kotlinlang.org/docs/multiplatform.html) | ||||||
| [-blue)](https://kotlinlang.org/docs/multiplatform.html) | ||||||
| [](https://kotlinlang.org/docs/multiplatform.html) | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Clarify “Native” scope or list targets. Consider mentioning the concrete KMP native targets (iOS/tvOS/watchOS/macOS, Linux, Windows) to set expectations, or link to a section that enumerates them. 🤖 Prompt for AI Agents |
||||||
| [](https://search.maven.org/search?q=g:io.modelcontextprotocol%20a:kotlin-sdk) | ||||||
| [](LICENSE) | ||||||
|
|
||||||
|
|
||||||
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -3,6 +3,7 @@ | |||||||||||||||||||||||||||||||||||||||||||||||
| import org.jetbrains.kotlin.gradle.ExperimentalWasmDsl | ||||||||||||||||||||||||||||||||||||||||||||||||
| import org.jetbrains.kotlin.gradle.dsl.ExplicitApiMode | ||||||||||||||||||||||||||||||||||||||||||||||||
| import org.jetbrains.kotlin.gradle.dsl.JvmTarget | ||||||||||||||||||||||||||||||||||||||||||||||||
| import org.jetbrains.kotlin.gradle.dsl.KotlinVersion.KOTLIN_2_1 | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| plugins { | ||||||||||||||||||||||||||||||||||||||||||||||||
| kotlin("multiplatform") | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
@@ -24,18 +25,40 @@ val generateLibVersion by tasks.registering { | |||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| public const val LIB_VERSION: String = "${project.version}" | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| """.trimIndent() | ||||||||||||||||||||||||||||||||||||||||||||||||
| """.trimIndent(), | ||||||||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| kotlin { | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| compilerOptions { | ||||||||||||||||||||||||||||||||||||||||||||||||
| languageVersion = KOTLIN_2_1 | ||||||||||||||||||||||||||||||||||||||||||||||||
| apiVersion = KOTLIN_2_1 | ||||||||||||||||||||||||||||||||||||||||||||||||
| // TODO: allWarningsAsErrors = true | ||||||||||||||||||||||||||||||||||||||||||||||||
| extraWarnings = true | ||||||||||||||||||||||||||||||||||||||||||||||||
| freeCompilerArgs = | ||||||||||||||||||||||||||||||||||||||||||||||||
| listOf( | ||||||||||||||||||||||||||||||||||||||||||||||||
| "-Xwhen-guards", | ||||||||||||||||||||||||||||||||||||||||||||||||
| ) | ||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||
| coreLibrariesVersion = "2.1.21" | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
+35
to
+46
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Compiler config for Kotlin 2.1 — LGTM; consider enabling Werror. Settings look correct for 2.1. Consider turning on allWarningsAsErrors once CI is green. - // TODO: allWarningsAsErrors = true
+ // Enable once the tree is clean
+ // allWarningsAsErrors = true📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||||||||||||||||||
| jvm { | ||||||||||||||||||||||||||||||||||||||||||||||||
| compilerOptions.jvmTarget = JvmTarget.JVM_1_8 | ||||||||||||||||||||||||||||||||||||||||||||||||
| compilerOptions { | ||||||||||||||||||||||||||||||||||||||||||||||||
| jvmTarget = JvmTarget.JVM_1_8 | ||||||||||||||||||||||||||||||||||||||||||||||||
| javaParameters = true | ||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||||||||||||||||||
| macosX64(); macosArm64() | ||||||||||||||||||||||||||||||||||||||||||||||||
| linuxX64(); linuxArm64() | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| macosX64() | ||||||||||||||||||||||||||||||||||||||||||||||||
| macosArm64() | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| linuxX64() | ||||||||||||||||||||||||||||||||||||||||||||||||
| linuxArm64() | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| mingwX64() | ||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| js { nodejs() } | ||||||||||||||||||||||||||||||||||||||||||||||||
| wasmJs { nodejs() } | ||||||||||||||||||||||||||||||||||||||||||||||||
|
Comment on lines
62
to
63
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) JS/Wasm target setup: ensure consistency with module-level kotlin blocks. This plugin sets js/wasm nodejs; kotlin-sdk-core also configures js { browser(); nodejs() }. Double-configuration is usually fine, but avoid divergent target declarations across plugin and module. - js { nodejs() }
- wasmJs { nodejs() }
+ // Consider centralizing target declarations either here or per-module to prevent drift.
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,5 +7,9 @@ org.jetbrains.dokka.experimental.gradle.pluginMode.noWarn=true | |
| # Kotlin | ||
| kotlin.code.style=official | ||
| kotlin.daemon.jvmargs=-Xmx4G | ||
| kotlin.native.ignoreDisabledTargets=true | ||
| # MPP | ||
| kotlin.mpp.enableCInteropCommonization=true | ||
|
|
||
| # Build JS targets using npm package manager https://kotlinlang.org/docs/js-project-setup.html#npm-dependencies | ||
| kotlin.js.yarn=false | ||
|
Comment on lines
+14
to
+15
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧹 Nitpick (assertive) Switching Kotlin/JS to npm: document Node/NPM expectations. With yarn disabled, ensure Node and npm are available in CI and optionally pin Node via a tool (e.g., actions/setup-node) to avoid non-reproducible builds. 🤖 Prompt for AI Agents |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick (assertive)
Specify minimum toolchain versions and quick install hints.
Add minimum versions (e.g., Xcode ≥ 15.x for current Kotlin/Native, Node.js ≥ LTS 18/20) and brief install commands to reduce setup friction.
What minimum versions are you targeting for:
🤖 Prompt for AI Agents