From 12d35560cd5a2e06a60aba651a63853a4e88225a Mon Sep 17 00:00:00 2001 From: Peefy Date: Fri, 16 Oct 2026 22:24:35 +0800 Subject: [PATCH 1/7] chore(release): bump KCL to v0.13.2 Moves KCL_VERSION in go/install/install.go and every binding's package version from 0.13.1 to 0.13.2, now that kcl-lang/kcl has cut v0.13.2. The prebuilt binaries every binding vendors are downloaded from that release, so the runtime pin and the package version have to move together. The kcl-* git dependencies move with it for a second reason: they are unpinned to the default branch, whose workspace version is already 0.13.2, so the 0.13.1 requirement no longer resolves. Renames the lua rockspec to match the new package_version, which publish-luarocks.yaml globs for by name. Comments recording what changed *in* v0.13.1 (the LoadPackageResult fields, the ListDepFiles removal) are left alone; they are historical. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Peefy --- .github/workflows/dotnet-test.yaml | 2 +- .github/workflows/publish-kcltool.yaml | 2 +- Cargo.toml | 14 +++++++------- README.md | 6 +++--- cpp/CMakeLists.txt | 2 +- cpp/Cargo.toml | 4 ++-- cpp/README.md | 4 ++-- dart/pubspec.yaml | 2 +- docs/lib-vendoring.md | 2 +- dotnet/Cargo.toml | 4 ++-- dotnet/Directory.Build.props | 2 +- dotnet/KclLib/KclLib.csproj | 2 +- .../examples/exec-program/exec-program.csproj | 2 +- go/install/install.go | 2 +- hack/download-libs.sh | 2 +- java/Cargo.toml | 8 ++++---- java/README.md | 2 +- java/pom.xml | 2 +- julia/Project.toml | 2 +- julia/README.md | 4 ++-- kotlin/Cargo.toml | 8 ++++---- kotlin/README.md | 2 +- kotlin/pom.xml | 2 +- lua/Cargo.toml | 4 ++-- ....1-3.rockspec => kcl_lib-0.13.2-3.rockspec} | 2 +- nodejs/Cargo.toml | 4 ++-- nodejs/examples/exec-program/package.json | 2 +- nodejs/npm/darwin-arm64/package.json | 2 +- nodejs/npm/darwin-x64/package.json | 2 +- nodejs/npm/linux-arm64-gnu/package.json | 2 +- nodejs/npm/linux-x64-gnu/package.json | 2 +- nodejs/npm/win32-arm64-msvc/package.json | 2 +- nodejs/npm/win32-x64-msvc/package.json | 2 +- nodejs/package.json | 18 +++++++++--------- nodejs/src/lib.rs | 4 ++-- python/Cargo.toml | 4 ++-- python/pyproject.toml | 2 +- ruby/Cargo.toml | 4 ++-- ruby/lib/kcl_lib/version.rb | 2 +- swift/Cargo.toml | 4 ++-- wasm/README.md | 6 +++--- wasm/package.json | 2 +- zig/build.zig.zon | 2 +- 43 files changed, 77 insertions(+), 77 deletions(-) rename lua/{kcl_lib-0.13.1-3.rockspec => kcl_lib-0.13.2-3.rockspec} (97%) diff --git a/.github/workflows/dotnet-test.yaml b/.github/workflows/dotnet-test.yaml index 3fc6cb03..3213184e 100644 --- a/.github/workflows/dotnet-test.yaml +++ b/.github/workflows/dotnet-test.yaml @@ -185,4 +185,4 @@ jobs: if: "startsWith(github.ref, 'refs/tags/')" run: | cd dotnet/KclLib/bin/Release - dotnet nuget push KclLib.0.13.1.nupkg -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json + dotnet nuget push KclLib.0.13.2.nupkg -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json diff --git a/.github/workflows/publish-kcltool.yaml b/.github/workflows/publish-kcltool.yaml index 420343ce..bcf3bd9a 100644 --- a/.github/workflows/publish-kcltool.yaml +++ b/.github/workflows/publish-kcltool.yaml @@ -29,7 +29,7 @@ on: env: KCL_CLI_VERSION: v0.12.10 KCL_LIB_REF: v0.12.5 - PACKAGE_VERSION: 0.13.1 + PACKAGE_VERSION: 0.13.2 jobs: build: diff --git a/Cargo.toml b/Cargo.toml index a98c48e5..2772e993 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kcl-lang" -version = "0.13.1" +version = "0.13.2" edition = "2024" readme = "README.md" documentation = "kcl-lang.io" @@ -11,12 +11,12 @@ license = "Apache-2.0" [dependencies] anyhow = "1" -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-evaluator = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-loader = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-runtime = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-primitives = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-evaluator = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-loader = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-runtime = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-primitives = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } [dev-dependencies] serde_json = "1" diff --git a/README.md b/README.md index 31b07c4e..5fd1f61d 100644 --- a/README.md +++ b/README.md @@ -103,7 +103,7 @@ This way you'll be able to import the above dependency to use the SDK. com.kcl kcl-lib - 0.13.1 + 0.13.2 ``` @@ -256,7 +256,7 @@ This way you'll be able to import the above dependency to use the SDK. com.kcl kcl-lib - 0.13.1 + 0.13.2 ``` @@ -340,7 +340,7 @@ For CMake, you can use FetchContent to add KCL C++ Lib to your project. FetchContent_Declare( kcl-lib GIT_REPOSITORY https://github.com/kcl-lang/lib.git - GIT_TAG v0.13.1 + GIT_TAG v0.13.2 SOURCE_SUBDIR cpp ) FetchContent_MakeAvailable(kcl-lib) diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt index e7574a0c..8253aba7 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.10) -project(kcl-lib VERSION 0.13.1 LANGUAGES C CXX) +project(kcl-lib VERSION 0.13.2 LANGUAGES C CXX) set(CMAKE_CXX_STANDARD 17) set(CMAKE_CXX_STANDARD_REQUIRED ON) diff --git a/cpp/Cargo.toml b/cpp/Cargo.toml index 04420d69..2f0fd22e 100644 --- a/cpp/Cargo.toml +++ b/cpp/Cargo.toml @@ -2,7 +2,7 @@ name = "kcl-lib-cpp" publish = false edition = "2024" -version = "0.13.1" +version = "0.13.2" [lib] crate-type = ["staticlib"] @@ -10,7 +10,7 @@ crate-type = ["staticlib"] [dependencies] anyhow = "1.0" cxx = "1.0" -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } # Used to encode the empty `ListMethodArgs` and decode `ListMethodResult` # through the universal `kcl_api::call` dispatcher since `KclServiceImpl` # does not expose a typed `list_method` wrapper. diff --git a/cpp/README.md b/cpp/README.md index 51e8128b..4e1dbfcd 100644 --- a/cpp/README.md +++ b/cpp/README.md @@ -12,7 +12,7 @@ You can use FetchContent to add KCL C++ Lib to your project. FetchContent_Declare( kcl-lib GIT_REPOSITORY https://github.com/kcl-lang/lib.git - GIT_TAG v0.13.1 + GIT_TAG v0.13.2 SOURCE_SUBDIR cpp ) FetchContent_MakeAvailable(kcl-lib) @@ -24,7 +24,7 @@ Or you can download the source code and add it to your project. mkdir third_party cd third_party git clone https://github.com/kcl-lang/lib.git -git checkout v0.13.1 +git checkout v0.13.2 ``` ```shell diff --git a/dart/pubspec.yaml b/dart/pubspec.yaml index 0ce24d4f..52c485e4 100644 --- a/dart/pubspec.yaml +++ b/dart/pubspec.yaml @@ -6,7 +6,7 @@ description: > the universal protobuf dispatcher shipped as a prebuilt `libkcl` shared library (see `go/lib/` in the parent repository). The Dart runtime never builds any Rust code. -version: 0.13.1 +version: 0.13.2 environment: # protoc_plugin 25.x and protobuf 6.x both require Dart SDK 3.7+. diff --git a/docs/lib-vendoring.md b/docs/lib-vendoring.md index 3be3d0c9..ff6fa8fd 100644 --- a/docs/lib-vendoring.md +++ b/docs/lib-vendoring.md @@ -21,7 +21,7 @@ hack/download-libs.sh linux-arm64 # named platforms ``` The version defaults to `KCL_VERSION` in `go/install/install.go`; pass -`--version v0.13.1` to pin a different one. Platforms that +`--version v0.13.2` to pin a different one. Platforms that [kcl-lang/kcl][kcl] publishes are downloaded from its release; the two iOS static archives are cross-compiled from this repository's `c/` crate with cargo, so `--all` needs a macOS host. diff --git a/dotnet/Cargo.toml b/dotnet/Cargo.toml index 1f4a65c3..ce3b1ecd 100644 --- a/dotnet/Cargo.toml +++ b/dotnet/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "kcl-lib-dotnet" publish = false -version = "0.13.1" +version = "0.13.2" edition = "2024" [lib] @@ -9,4 +9,4 @@ crate-type = ["cdylib"] doc = false [dependencies] -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } diff --git a/dotnet/Directory.Build.props b/dotnet/Directory.Build.props index 82c2d623..ca8fe9fb 100644 --- a/dotnet/Directory.Build.props +++ b/dotnet/Directory.Build.props @@ -8,7 +8,7 @@ --> - 0.13.1 + 0.13.2 Apache-2.0 https://github.com/kcl-lang/lib git diff --git a/dotnet/KclLib/KclLib.csproj b/dotnet/KclLib/KclLib.csproj index fe37e1b5..67676403 100644 --- a/dotnet/KclLib/KclLib.csproj +++ b/dotnet/KclLib/KclLib.csproj @@ -11,7 +11,7 @@ KclLib KclLib - 0.13.1 + 0.13.2 true snupkg https://github.com/kcl-lang diff --git a/dotnet/examples/exec-program/exec-program.csproj b/dotnet/examples/exec-program/exec-program.csproj index e189f9a3..4dcff449 100644 --- a/dotnet/examples/exec-program/exec-program.csproj +++ b/dotnet/examples/exec-program/exec-program.csproj @@ -9,7 +9,7 @@ - + diff --git a/go/install/install.go b/go/install/install.go index f501b049..c085fa74 100644 --- a/go/install/install.go +++ b/go/install/install.go @@ -9,7 +9,7 @@ import ( "github.com/gofrs/flock" ) -const KCL_VERSION = "v0.13.1" +const KCL_VERSION = "v0.13.2" func getVersion() string { return fmt.Sprintf("%s-%s-%s", KCL_VERSION, runtime.GOOS, runtime.GOARCH) diff --git a/hack/download-libs.sh b/hack/download-libs.sh index f408a459..84120db7 100755 --- a/hack/download-libs.sh +++ b/hack/download-libs.sh @@ -13,7 +13,7 @@ # hack/download-libs.sh linux-arm64 darwin-arm64 # named platforms # hack/download-libs.sh --wasm # kcl.wasm (npm package) # hack/download-libs.sh --all # every platform, incl. iOS -# hack/download-libs.sh --version v0.13.1 # pin a version +# hack/download-libs.sh --version v0.13.2 # pin a version # # --all includes the two iOS static archives, which have no prebuilt source # and are cross-compiled from c/ with cargo (macOS hosts only). diff --git a/java/Cargo.toml b/java/Cargo.toml index 181eb6bc..32c2ae27 100644 --- a/java/Cargo.toml +++ b/java/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "kcl-lib-jni" publish = false -version = "0.13.1" +version = "0.13.2" edition = "2024" [lib] @@ -19,6 +19,6 @@ lazy_static = "1.4.0" prost = "0.14.1" prost-types = "0.14.1" -kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-sema = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-sema = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } diff --git a/java/README.md b/java/README.md index 1a57e5f3..8f7bff02 100644 --- a/java/README.md +++ b/java/README.md @@ -26,7 +26,7 @@ This way you'll be able to import the above dependency to use the SDK. io.kcl-lang kcl-lib - 0.13.1 + 0.13.2 ``` diff --git a/java/pom.xml b/java/pom.xml index fc855364..cdbfe9d9 100644 --- a/java/pom.xml +++ b/java/pom.xml @@ -5,7 +5,7 @@ io.kcl-lang kcl-lib - 0.13.1 + 0.13.2 KCL Arifact Library for Java KCL is an open-source constraint-based record and functional language mainly diff --git a/julia/Project.toml b/julia/Project.toml index d526127a..3079259d 100644 --- a/julia/Project.toml +++ b/julia/Project.toml @@ -1,6 +1,6 @@ name = "KclLib" uuid = "739c31e6-accf-4447-b2e8-a9920cc4cdad" -version = "0.13.1" +version = "0.13.2" [deps] Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb" diff --git a/julia/README.md b/julia/README.md index d15f32b4..dcc89980 100644 --- a/julia/README.md +++ b/julia/README.md @@ -112,7 +112,7 @@ result = ping(PingArgs(value="Hello, KCL!")) ```julia result = get_version() -println(result.version_info) # "Version: 0.13.1-...\nPlatform: ...\nGitCommit: ..." +println(result.version_info) # "Version: 0.13.2-...\nPlatform: ...\nGitCommit: ..." ``` ### exec_program @@ -431,7 +431,7 @@ println(result.method_name_list) core registers under `KclService` regardless of what the spec says. The wrapper follows the registration, so it calls `BuiltinService.ListMethod`; `KclService.ListMethod` is not registered and makes the dispatcher raise -`unknown method name`. Against the prebuilt `libkcl` v0.13.1 this returns the +`unknown method name`. Against the prebuilt `libkcl` v0.13.2 this returns the full 28-entry table, reported by fully-qualified name. ### Raw call diff --git a/kotlin/Cargo.toml b/kotlin/Cargo.toml index 181eb6bc..32c2ae27 100644 --- a/kotlin/Cargo.toml +++ b/kotlin/Cargo.toml @@ -1,7 +1,7 @@ [package] name = "kcl-lib-jni" publish = false -version = "0.13.1" +version = "0.13.2" edition = "2024" [lib] @@ -19,6 +19,6 @@ lazy_static = "1.4.0" prost = "0.14.1" prost-types = "0.14.1" -kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-sema = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-parser = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-sema = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } diff --git a/kotlin/README.md b/kotlin/README.md index 56e2bdbb..9859e0e5 100644 --- a/kotlin/README.md +++ b/kotlin/README.md @@ -26,7 +26,7 @@ This way you'll be able to import the above dependency to use the SDK. io.kcl-lang kcl-lib-kotlin - 0.13.1 + 0.13.2 ``` diff --git a/kotlin/pom.xml b/kotlin/pom.xml index 3589a658..5b15f42b 100644 --- a/kotlin/pom.xml +++ b/kotlin/pom.xml @@ -5,7 +5,7 @@ io.kcl-lang kcl-lib-kotlin - 0.13.1 + 0.13.2 KCL Arifact Library for Kotlin KCL is an open-source constraint-based record and functional language mainly diff --git a/lua/Cargo.toml b/lua/Cargo.toml index dd5da465..5e6bd6ab 100644 --- a/lua/Cargo.toml +++ b/lua/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "kcl-lib-lua" -version = "0.13.1" +version = "0.13.2" edition = "2024" publish = false @@ -24,4 +24,4 @@ mlua = { version = "0.12", features = [ "module", "macros", ], default-features = false, optional = true } -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } diff --git a/lua/kcl_lib-0.13.1-3.rockspec b/lua/kcl_lib-0.13.2-3.rockspec similarity index 97% rename from lua/kcl_lib-0.13.1-3.rockspec rename to lua/kcl_lib-0.13.2-3.rockspec index 25378685..2f279297 100644 --- a/lua/kcl_lib-0.13.1-3.rockspec +++ b/lua/kcl_lib-0.13.2-3.rockspec @@ -1,4 +1,4 @@ -local package_version = "0.13.1" +local package_version = "0.13.2" local rockspec_revision = "3" rockspec_format = "3.0" diff --git a/nodejs/Cargo.toml b/nodejs/Cargo.toml index 33002837..f4561cd4 100644 --- a/nodejs/Cargo.toml +++ b/nodejs/Cargo.toml @@ -1,13 +1,13 @@ [package] edition = "2024" name = "kcl-nodejs-lib" -version = "0.13.1" +version = "0.13.2" [lib] crate-type = ["cdylib"] [dependencies] -kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.1" } +kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } # Default enable napi4 feature, see https://nodejs.org/api/n-api.html#node-api-version-matrix napi = { version = "2.12.2", default-features = false, features = ["napi4"] } napi-derive = "2.12.2" diff --git a/nodejs/examples/exec-program/package.json b/nodejs/examples/exec-program/package.json index 7fd2adcd..c1f1e67d 100644 --- a/nodejs/examples/exec-program/package.json +++ b/nodejs/examples/exec-program/package.json @@ -12,6 +12,6 @@ "dist/" ], "dependencies": { - "@kcl-lib/native": "0.13.1" + "@kcl-lib/native": "0.13.2" } } diff --git a/nodejs/npm/darwin-arm64/package.json b/nodejs/npm/darwin-arm64/package.json index 7d57062d..caad506b 100644 --- a/nodejs/npm/darwin-arm64/package.json +++ b/nodejs/npm/darwin-arm64/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-darwin-arm64", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "darwin" ], diff --git a/nodejs/npm/darwin-x64/package.json b/nodejs/npm/darwin-x64/package.json index ceb3152c..1ed87776 100644 --- a/nodejs/npm/darwin-x64/package.json +++ b/nodejs/npm/darwin-x64/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-darwin-x64", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "darwin" ], diff --git a/nodejs/npm/linux-arm64-gnu/package.json b/nodejs/npm/linux-arm64-gnu/package.json index a5b96c57..3552d08d 100644 --- a/nodejs/npm/linux-arm64-gnu/package.json +++ b/nodejs/npm/linux-arm64-gnu/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-linux-arm64-gnu", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "linux" ], diff --git a/nodejs/npm/linux-x64-gnu/package.json b/nodejs/npm/linux-x64-gnu/package.json index 51efe919..08f6ca24 100644 --- a/nodejs/npm/linux-x64-gnu/package.json +++ b/nodejs/npm/linux-x64-gnu/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-linux-x64-gnu", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "linux" ], diff --git a/nodejs/npm/win32-arm64-msvc/package.json b/nodejs/npm/win32-arm64-msvc/package.json index 5834a3de..33832c45 100644 --- a/nodejs/npm/win32-arm64-msvc/package.json +++ b/nodejs/npm/win32-arm64-msvc/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-win32-arm64-msvc", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "win32" ], diff --git a/nodejs/npm/win32-x64-msvc/package.json b/nodejs/npm/win32-x64-msvc/package.json index c33511cd..9d0940b7 100644 --- a/nodejs/npm/win32-x64-msvc/package.json +++ b/nodejs/npm/win32-x64-msvc/package.json @@ -1,7 +1,7 @@ { "name": "@kcl-lib/native-win32-x64-msvc", "repository": "https://github.com/kcl-lang/lib", - "version": "0.13.1", + "version": "0.13.2", "os": [ "win32" ], diff --git a/nodejs/package.json b/nodejs/package.json index 23791aca..c222e23a 100644 --- a/nodejs/package.json +++ b/nodejs/package.json @@ -1,6 +1,6 @@ { "name": "@kcl-lib/native", - "version": "0.13.1", + "version": "0.13.2", "repository": "https://github.com/kcl-lang/lib", "license": "Apache-2.0", "main": "index.js", @@ -94,13 +94,13 @@ "access": "public" }, "optionalDependencies": { - "@kcl-lib/native-win32-x64-msvc": "0.13.1", - "@kcl-lib/native-darwin-x64": "0.13.1", - "@kcl-lib/native-linux-x64-gnu": "0.13.1", - "@kcl-lib/native-darwin-arm64": "0.13.1", - "@kcl-lib/native-linux-arm64-gnu": "0.13.1", - "@kcl-lib/native-linux-arm64-musl": "0.13.1", - "@kcl-lib/native-linux-x64-musl": "0.13.1", - "@kcl-lib/native-win32-arm64-msvc": "0.13.1" + "@kcl-lib/native-win32-x64-msvc": "0.13.2", + "@kcl-lib/native-darwin-x64": "0.13.2", + "@kcl-lib/native-linux-x64-gnu": "0.13.2", + "@kcl-lib/native-darwin-arm64": "0.13.2", + "@kcl-lib/native-linux-arm64-gnu": "0.13.2", + "@kcl-lib/native-linux-arm64-musl": "0.13.2", + "@kcl-lib/native-linux-x64-musl": "0.13.2", + "@kcl-lib/native-win32-arm64-msvc": "0.13.2" } } diff --git a/nodejs/src/lib.rs b/nodejs/src/lib.rs index d9413890..89d53303 100644 --- a/nodejs/src/lib.rs +++ b/nodejs/src/lib.rs @@ -763,7 +763,7 @@ pub fn list_method() -> Result { * Like `list_method` above, this routes through the universal `kcl_api::call` * dispatcher rather than a typed `KclServiceImpl` wrapper. It was written when * the pinned `kcl-api` revision predated `KclService.FormatTestReport`. The pin -* is now 0.13.1, which has both the typed wrapper and the generated messages; +* is now 0.13.2, which has both the typed wrapper and the generated messages; * the hand-rolled encoding is kept because it is already covered by tests, and * it collapses to the typed call wherever that is tidier. `FormatTestReportArgs` * is a single length-delimited field 1 carrying a `TestResult`, and @@ -838,7 +838,7 @@ pub fn format_test_report(args: FormatTestReportArgs) -> Result "0.13.1" +console.log(invokeKCLVersion(inst)); // -> "0.13.2" // Dispatch any KclService.* RPC by name. The `args` field must be the // protobuf-encoded `Args` message, and the returned string is @@ -74,7 +74,7 @@ import { load, ping, lintPath, getVersion } from "@kcl-lib/wasm"; const inst = await load(); console.log(ping(inst, { value: "hello" }).value); // -> "hello" -console.log(getVersion(inst).version); // -> "0.13.1" +console.log(getVersion(inst).version); // -> "0.13.2" // File-based methods operate on the WASI sandbox filesystem. const result = lintPath(inst, { paths: ["/test.k"] }); @@ -240,7 +240,7 @@ MemFS()` instance to `load()` to set up the sandbox filesystem. `panic=abort` caveat above applies to plugin errors specifically, because the runtime reports them by panicking. - **`Generate*` and `FormatTestReport` are registered and run.** The - bundled v0.13.1 artifact advertises them in `listMethod` and the + bundled v0.13.2 artifact advertises them in `listMethod` and the consistency runner asserts them for real. Two of them still diverge from the native goldens and are reported as skips with the measured reason: `GenerateProto` emits a referenced schema twice, and `GenerateDoc` diff --git a/wasm/package.json b/wasm/package.json index e63ae271..72d3433f 100644 --- a/wasm/package.json +++ b/wasm/package.json @@ -1,6 +1,6 @@ { "name": "@kcl-lib/wasm", - "version": "0.13.1", + "version": "0.13.2", "description": "KCL WASM module", "files": [ "kcl.wasm", diff --git a/zig/build.zig.zon b/zig/build.zig.zon index 0c83b094..d03f64c8 100644 --- a/zig/build.zig.zon +++ b/zig/build.zig.zon @@ -11,7 +11,7 @@ // This is a [Semantic Version](https://semver.org/). // In a future version of Zig it will be used for package deduplication. - .version = "0.13.1", + .version = "0.13.2", // Together with name, this represents a globally unique package // identifier. This field is generated by the Zig toolchain when the From 9068ece966c65a8e35fffbd86b52153066fc47f2 Mon Sep 17 00:00:00 2001 From: Peefy Date: Fri, 16 Oct 2026 22:24:35 +0800 Subject: [PATCH 2/7] feat(python): build wheels for CPython 3.15 Moves pyo3 from the pinned 0.20.2 to 0.30, the first line with final Python 3.15 support, and gives the wheel jobs a Python dimension so a cp315 leg actually gets built. Closes #404. The pyo3 pin was `=0.20.2` because of PyO3/maturin#1960, where the action built against interpreters newer than pyo3's documented ceiling (3.12) and hard-failed. That issue closed in Feb 2024 once maturin 1.5 stopped detecting too-new interpreters, so the pin has been load-bearing for nothing for two years. cp313/cp314 only worked because the workflow also set PYO3_USE_ABI3_FORWARD_COMPATIBILITY=1, which is exactly the escape hatch that issue was about; with 0.30 that variable is dropped. The only source change is the #[pymodule] signature, which takes &Bound<'_, PyModule> under the post-0.21 API. The &PyModule-to-Bound migration is otherwise the whole surface -- this crate uses two #[pyfunction]s and nothing else. requires-python moves 3.7 -> 3.9 to match pyo3 0.30's own floor. Note protobuf >=7.36.2 already requires >=3.10, so the cp37/cp38 wheels that were being published could not actually install; that pre-existing gap is unchanged by this commit. Verified locally on 3.14 with maturin 1.15.0: builds, 176 tests pass. The 3.15 legs themselves can only be exercised in CI. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Peefy --- .github/workflows/ast-diff-test.yaml | 1 + .github/workflows/python-test.yaml | 87 ++++++++++++++++++---------- python/Cargo.toml | 6 +- python/pyproject.toml | 7 ++- python/src/lib.rs | 2 +- 5 files changed, 65 insertions(+), 38 deletions(-) diff --git a/.github/workflows/ast-diff-test.yaml b/.github/workflows/ast-diff-test.yaml index 8494cabd..1fc7c849 100644 --- a/.github/workflows/ast-diff-test.yaml +++ b/.github/workflows/ast-diff-test.yaml @@ -182,6 +182,7 @@ jobs: if: matrix.binding == 'python' uses: PyO3/maturin-action@v1 with: + maturin-version: v1.15.0 command: develop working-directory: lib/python env: diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index 5230b242..805a6214 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -1,8 +1,7 @@ -# This file is autogenerated by maturin v1.5.1 -# To update, run -# -# maturin generate-ci github -# +# Derived from `maturin generate-ci github`, but hand-maintained since: +# the wheel jobs gained a Python-version dimension and the `test` job carries +# comments explaining why it builds in place. Re-running the generator would +# drop both, so edit this file directly and keep it in sync with maturin's shape. name: python-test on: @@ -29,9 +28,6 @@ on: permissions: contents: read -env: - PYO3_USE_ABI3_FORWARD_COMPATIBILITY: 1 - jobs: sdist: runs-on: ubuntu-latest @@ -39,6 +35,7 @@ jobs: - uses: actions/checkout@v7 - uses: PyO3/maturin-action@v1 with: + maturin-version: v1.15.0 working-directory: "python" command: sdist args: -o dist @@ -48,73 +45,104 @@ jobs: name: sdist-${{ github.run_id }} path: python/dist + # The `python` dimension selects the interpreter each wheel is built against; + # `default` keeps whatever the runner ships, which is what produced every + # wheel up to cp314. Add a leg here for a new CPython. + # + # Linux builds inside a maturin-managed manylinux container, so `-i` is the + # only thing that selects the interpreter there -- installing Python on the + # runner would have no effect on the build. macOS and Windows build on the + # host, so those jobs select it with actions/setup-python instead. linux: runs-on: ubuntu-latest strategy: matrix: target: [ x86_64, aarch64 ] + python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 - uses: PyO3/maturin-action@v1 with: + maturin-version: v1.15.0 target: ${{ matrix.target }} manylinux: auto working-directory: "python" command: build - args: --release -o dist --find-interpreter + args: --release -o dist --find-interpreter ${{ matrix.python != 'default' && format('-i python{0}', matrix.python) || '' }} env: # Workaround ring 0.17 build issue CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" - - name: Upload wheels-linux-${{ matrix.target }}-${{ github.run_id }} + - name: Upload wheels-linux-${{ matrix.target }}-${{ matrix.python }}-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-linux-${{ matrix.target }}-${{ github.run_id }} + name: wheels-linux-${{ matrix.target }}-${{ matrix.python }}-${{ github.run_id }} path: python/dist windows: runs-on: windows-latest + strategy: + matrix: + python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 + - name: Set up Python ${{ matrix.python }} + if: matrix.python != 'default' + uses: actions/setup-python@v7 + with: + python-version: ${{ matrix.python }} - uses: PyO3/maturin-action@v1 with: + maturin-version: v1.15.0 working-directory: "python" command: build args: --release -o dist --find-interpreter - - name: Upload wheels-windows-${{ github.run_id }} + - name: Upload wheels-windows-${{ matrix.python }}-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-windows-${{ github.run_id }} + name: wheels-windows-${{ matrix.python }}-${{ github.run_id }} path: python/dist macos: runs-on: macos-latest + strategy: + matrix: + python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 + - name: Set up Python ${{ matrix.python }} + if: matrix.python != 'default' + uses: actions/setup-python@v7 + with: + python-version: ${{ matrix.python }} - uses: PyO3/maturin-action@v1 with: + maturin-version: v1.15.0 working-directory: "python" command: build target: universal2-apple-darwin args: --release -o dist --find-interpreter - - name: Upload wheels-macos-${{ github.run_id }} + - name: Upload wheels-macos-${{ matrix.python }}-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-macos-${{ github.run_id }} + name: wheels-macos-${{ matrix.python }}-${{ github.run_id }} path: python/dist test: - name: Test on ${{ matrix.os }} + name: Test on ${{ matrix.os }} / ${{ matrix.python }} runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-latest, macos-latest, windows-latest] + # "3.x" is the runner default; 3.15 is the newest CPython the wheels + # ship, and the newest is the one most likely to break. + python: [ "3.x", "3.15" ] steps: - uses: actions/checkout@v7 - name: Set up Python uses: actions/setup-python@v7 with: - python-version: "3.x" + python-version: ${{ matrix.python }} # Build the extension in-place via maturin develop so that the compiled # `_kcl_lib..so` is placed inside `python/kcl_lib/` alongside its # Python source. This matters because the tests run with `working-directory: @@ -127,9 +155,9 @@ jobs: run: | python -m venv .venv if [ "$RUNNER_OS" = "Windows" ]; then - .venv/Scripts/pip install maturin pytest + .venv/Scripts/pip install maturin==1.15.0 pytest else - .venv/bin/pip install maturin pytest + .venv/bin/pip install maturin==1.15.0 pytest fi - name: Build extension in-place with maturin working-directory: "python" @@ -159,22 +187,17 @@ jobs: id-token: write needs: [ macos, linux, windows ] steps: + # Collect every wheel leg in one step. The explicit per-name list this + # replaces had to be hand-edited for every new target, platform, or + # Python version; the pattern picks all of them up. `merge-multiple` + # keeps them flat in python/dist rather than nesting a directory per + # artifact. `wheels-` deliberately excludes the sdist artifact, which is + # published separately and not wanted here. - uses: actions/download-artifact@v8 with: - name: wheels-linux-x86_64-${{ github.run_id }} - path: python/dist - - uses: actions/download-artifact@v8 - with: - name: wheels-linux-aarch64-${{ github.run_id }} - path: python/dist - - uses: actions/download-artifact@v8 - with: - name: wheels-windows-${{ github.run_id }} - path: python/dist - - uses: actions/download-artifact@v8 - with: - name: wheels-macos-${{ github.run_id }} + pattern: wheels-*-${{ github.run_id }} path: python/dist + merge-multiple: true - name: Publish to PyPI # The issue https://github.com/pypa/gh-action-pypi-publish/issues/310 has not tagged a release yet # Use the commit hash to get the temporary fix diff --git a/python/Cargo.toml b/python/Cargo.toml index c5b7b326..65dda6bf 100644 --- a/python/Cargo.toml +++ b/python/Cargo.toml @@ -9,6 +9,6 @@ crate-type = ["cdylib"] [dependencies] kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } -# fix the pyos version to 0.20.1 -# because https://github.com/PyO3/maturin/issues/1960 -pyo3 = "=0.20.2" +# 0.30 is the first line with final Python 3.15 support (0.29 had it as beta). +# It requires Python >=3.9, which is why `requires-python` is not lower. +pyo3 = "0.30" diff --git a/python/pyproject.toml b/python/pyproject.toml index a5e1b959..8bbf3458 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -1,11 +1,14 @@ [build-system] -requires = ["maturin>=1.5,<2.0"] +# 1.14 is the first release that knows about Python 3.15; 1.15.0 is what CI +# pins. The old floor of 1.5 predates both the pyo3 pin it was working around +# and any CPython this project targets. +requires = ["maturin>=1.14,<2.0"] build-backend = "maturin" [project] name = "kcl_lib" version = "0.13.2" -requires-python = ">=3.7" +requires-python = ">=3.9" classifiers = [ "Programming Language :: Rust", "Programming Language :: Python :: Implementation :: CPython", diff --git a/python/src/lib.rs b/python/src/lib.rs index d44b06ec..e159e8c4 100644 --- a/python/src/lib.rs +++ b/python/src/lib.rs @@ -21,7 +21,7 @@ fn call_with_plugin_agent<'a>( /// A Python module implemented in Rust. #[pymodule] -fn _kcl_lib(_py: Python, m: &PyModule) -> PyResult<()> { +fn _kcl_lib(m: &Bound<'_, PyModule>) -> PyResult<()> { m.add_function(wrap_pyfunction!(call, m)?)?; m.add_function(wrap_pyfunction!(call_with_plugin_agent, m)?)?; Ok(()) From f4d301e22887e90d548d8c9c6e92c1e31f8a079e Mon Sep 17 00:00:00 2001 From: Peefy Date: Fri, 16 Oct 2026 23:11:50 +0800 Subject: [PATCH 3/7] fix(ci): do not pass -i alongside --find-interpreter maturin rejects the two together, so the Linux 3.15 leg died on `--find-interpreter cannot be used with --interpreter`. The pinned leg now passes `-i python3.15` alone and the default leg keeps `--find-interpreter` alone; previously the expression appended `-i` on top of an unconditional `--find-interpreter`. Caught by CI, not locally: the Linux job builds inside the manylinux container, while a local `maturin develop` is a host build that never passes `-i`. Windows 3.15 and the 3.15 test legs passed, which is why only the linux jobs failed. Co-Authored-By: Claude Opus 4.6 Signed-off-by: Peefy --- .github/workflows/python-test.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index 805a6214..26f816be 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -51,8 +51,10 @@ jobs: # # Linux builds inside a maturin-managed manylinux container, so `-i` is the # only thing that selects the interpreter there -- installing Python on the - # runner would have no effect on the build. macOS and Windows build on the - # host, so those jobs select it with actions/setup-python instead. + # runner would have no effect on the build. maturin rejects `-i` together + # with `--find-interpreter`, so each leg passes exactly one. macOS and + # Windows build on the host, so those jobs select it with + # actions/setup-python and let `--find-interpreter` resolve it. linux: runs-on: ubuntu-latest strategy: @@ -68,7 +70,7 @@ jobs: manylinux: auto working-directory: "python" command: build - args: --release -o dist --find-interpreter ${{ matrix.python != 'default' && format('-i python{0}', matrix.python) || '' }} + args: --release -o dist ${{ matrix.python != 'default' && format('-i python{0}', matrix.python) || '--find-interpreter' }} env: # Workaround ring 0.17 build issue CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" From 363c68776996a6258e3e135b647799fab5e014f3 Mon Sep 17 00:00:00 2001 From: Peefy Date: Mon, 19 Oct 2026 09:51:36 +0800 Subject: [PATCH 4/7] fix(ci): drop redundant Python legs from the wheel jobs maturin's --find-interpreter means "build for every interpreter it finds", not "build for the default one". The runner images already carry a range: the manylinux container ships 3.9-3.15 plus free-threaded and PyPy, the macOS image carries 3.15. So the explicit 3.15 legs were rebuilding wheels the default legs had already produced, and macOS produced a byte-identical cp315 wheel under two artifact names, which collide once the release job merges artifacts. Windows is the exception: its image stops at 3.14, so that job now installs 3.15 explicitly. setup-python adds to what maturin discovers rather than replacing it, so 3.10-3.14 from the image are still built. The test job keeps its 3.x/3.15 matrix -- there the version selects what is exercised rather than what is packaged, so both legs are worth running. Signed-off-by: Peefy --- .github/workflows/python-test.yaml | 54 +++++++++++++----------------- 1 file changed, 23 insertions(+), 31 deletions(-) diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index 26f816be..8563f6a9 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -45,22 +45,23 @@ jobs: name: sdist-${{ github.run_id }} path: python/dist - # The `python` dimension selects the interpreter each wheel is built against; - # `default` keeps whatever the runner ships, which is what produced every - # wheel up to cp314. Add a leg here for a new CPython. + # These jobs build a wheel for *every* interpreter available to maturin, + # not one -- `--find-interpreter` means "find them all", and it picks up + # whatever the image ships plus anything on PATH. That is where the + # cp310..cp315 / pp311 spread comes from; there is no version matrix here + # and adding one would only duplicate wheels the default build already + # produces. # - # Linux builds inside a maturin-managed manylinux container, so `-i` is the - # only thing that selects the interpreter there -- installing Python on the - # runner would have no effect on the build. maturin rejects `-i` together - # with `--find-interpreter`, so each leg passes exactly one. macOS and - # Windows build on the host, so those jobs select it with - # actions/setup-python and let `--find-interpreter` resolve it. + # Linux runs inside the manylinux container, which ships 3.9 through 3.15 + # (plus free-threaded 3.14t/3.15t and PyPy 3.11), so its cp315 comes for + # free. The macOS runner image also carries 3.15. The Windows image stops + # at 3.14, so that job installs 3.15 explicitly below -- setup-python adds + # to what maturin discovers rather than replacing it. linux: runs-on: ubuntu-latest strategy: matrix: target: [ x86_64, aarch64 ] - python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 - uses: PyO3/maturin-action@v1 @@ -70,52 +71,43 @@ jobs: manylinux: auto working-directory: "python" command: build - args: --release -o dist ${{ matrix.python != 'default' && format('-i python{0}', matrix.python) || '--find-interpreter' }} + args: --release -o dist --find-interpreter env: # Workaround ring 0.17 build issue CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" - - name: Upload wheels-linux-${{ matrix.target }}-${{ matrix.python }}-${{ github.run_id }} + - name: Upload wheels-linux-${{ matrix.target }}-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-linux-${{ matrix.target }}-${{ matrix.python }}-${{ github.run_id }} + name: wheels-linux-${{ matrix.target }}-${{ github.run_id }} path: python/dist windows: runs-on: windows-latest - strategy: - matrix: - python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 - - name: Set up Python ${{ matrix.python }} - if: matrix.python != 'default' + # The Windows image tops out at 3.14. Without this the cp315 wheel + # never gets built; with it maturin finds 3.10-3.14 from the image + # plus 3.15 here. + - name: Set up Python 3.15 uses: actions/setup-python@v7 with: - python-version: ${{ matrix.python }} + python-version: "3.15" - uses: PyO3/maturin-action@v1 with: maturin-version: v1.15.0 working-directory: "python" command: build args: --release -o dist --find-interpreter - - name: Upload wheels-windows-${{ matrix.python }}-${{ github.run_id }} + - name: Upload wheels-windows-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-windows-${{ matrix.python }}-${{ github.run_id }} + name: wheels-windows-${{ github.run_id }} path: python/dist macos: runs-on: macos-latest - strategy: - matrix: - python: [ default, "3.15" ] steps: - uses: actions/checkout@v7 - - name: Set up Python ${{ matrix.python }} - if: matrix.python != 'default' - uses: actions/setup-python@v7 - with: - python-version: ${{ matrix.python }} - uses: PyO3/maturin-action@v1 with: maturin-version: v1.15.0 @@ -123,10 +115,10 @@ jobs: command: build target: universal2-apple-darwin args: --release -o dist --find-interpreter - - name: Upload wheels-macos-${{ matrix.python }}-${{ github.run_id }} + - name: Upload wheels-macos-${{ github.run_id }} uses: actions/upload-artifact@v7 with: - name: wheels-macos-${{ matrix.python }}-${{ github.run_id }} + name: wheels-macos-${{ github.run_id }} path: python/dist test: From 0e980a6805b7d8b02756433bc8cacb88092f6934 Mon Sep 17 00:00:00 2001 From: Peefy Date: Mon, 19 Oct 2026 10:24:17 +0800 Subject: [PATCH 5/7] fix(ci): build the aarch64 3.15 wheel explicitly maturin-action cross-compiles aarch64 in ghcr.io/rust-cross/manylinux2014-cross:aarch64, whose /opt/python stops at CPython 3.14. --find-interpreter therefore reports 3.9-3.14, 3.14t and PyPy 3.11 there and never offers 3.15, even though the interpreter itself is present -- naming it explicitly resolves fine. The x86_64 leg is unaffected: it builds in the native manylinux image, which does ship 3.15. So after dropping the redundant 3.15 legs, aarch64 Linux shipped no 3.15 wheel at all -- the exact gap #404 asks to close. This restores it for aarch64 only, where it is the difference between having the wheel and not. The free-threaded 3.15t build is separate and non-fatal: the cross image may not carry 3.15t, and that should not take the cp315 wheel down with it. If it turns out to be present, the step can be made fatal. Signed-off-by: Peefy --- .github/workflows/python-test.yaml | 49 +++++++++++++++++++++++++++--- 1 file changed, 44 insertions(+), 5 deletions(-) diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index 8563f6a9..d348af37 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -52,11 +52,11 @@ jobs: # and adding one would only duplicate wheels the default build already # produces. # - # Linux runs inside the manylinux container, which ships 3.9 through 3.15 - # (plus free-threaded 3.14t/3.15t and PyPy 3.11), so its cp315 comes for - # free. The macOS runner image also carries 3.15. The Windows image stops - # at 3.14, so that job installs 3.15 explicitly below -- setup-python adds - # to what maturin discovers rather than replacing it. + # Linux x86_64 runs in the native manylinux image, which ships 3.9 through + # 3.15 (plus free-threaded 3.14t/3.15t and PyPy 3.11), so its cp315 comes + # for free. The macOS runner image also carries 3.15. The Windows image + # stops at 3.14, so that job installs 3.15 explicitly below -- setup-python + # adds to what maturin discovers rather than replacing it. linux: runs-on: ubuntu-latest strategy: @@ -75,6 +75,45 @@ jobs: env: # Workaround ring 0.17 build issue CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" + # aarch64 is a cross build, so maturin-action runs it in + # ghcr.io/rust-cross/manylinux2014-cross:aarch64 rather than the native + # quay.io/pypa/manylinux2014_x86_64 image the x86_64 leg uses. That + # cross image's /opt/python stops at CPython 3.14, so --find-interpreter + # never offers 3.15 there -- it reports 3.9 through 3.14, 3.14t and + # PyPy 3.11 and stops. The interpreter itself is present, so naming it + # explicitly works. Without this step aarch64 Linux ships no 3.15 wheel + # at all, which is the gap #404 is about. + - name: Build the aarch64 CPython 3.15 wheel + if: matrix.target == 'aarch64' + uses: PyO3/maturin-action@v1 + with: + maturin-version: v1.15.0 + target: aarch64 + manylinux: auto + working-directory: "python" + command: build + args: --release -o dist -i python3.15 + env: + # Workaround ring 0.17 build issue + CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" + # Free-threaded 3.15 on aarch64, if the cross image has it. The x86_64 + # leg gets cp315t from the native image; this is the same question asked + # of the cross image, and it is allowed to fail so that a missing 3.15t + # cannot take the cp315 wheel above down with it. + - name: Build the aarch64 free-threaded 3.15 wheel + if: matrix.target == 'aarch64' + continue-on-error: true + uses: PyO3/maturin-action@v1 + with: + maturin-version: v1.15.0 + target: aarch64 + manylinux: auto + working-directory: "python" + command: build + args: --release -o dist -i python3.15t + env: + # Workaround ring 0.17 build issue + CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" - name: Upload wheels-linux-${{ matrix.target }}-${{ github.run_id }} uses: actions/upload-artifact@v7 with: From c73f9bffa2f3d4a9d65034cadba0625d34f1fbd2 Mon Sep 17 00:00:00 2001 From: Peefy Date: Mon, 19 Oct 2026 10:53:56 +0800 Subject: [PATCH 6/7] fix(ci): make the aarch64 free-threaded 3.15 build fatal The step was non-fatal while it was a probe. CI confirms the cross image does carry 3.15t -- maturin just never offers it to --find-interpreter -- so the aarch64 artifact now matches x86_64 exactly: cp39, cp310-cp315, cp314t, cp315t and PyPy 3.11. Signed-off-by: Peefy --- .github/workflows/python-test.yaml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index d348af37..e68aa473 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -56,7 +56,9 @@ jobs: # 3.15 (plus free-threaded 3.14t/3.15t and PyPy 3.11), so its cp315 comes # for free. The macOS runner image also carries 3.15. The Windows image # stops at 3.14, so that job installs 3.15 explicitly below -- setup-python - # adds to what maturin discovers rather than replacing it. + # adds to what maturin discovers rather than replacing it. Linux aarch64 + # needs its own steps for the same reason, but for a different one; see + # below. linux: runs-on: ubuntu-latest strategy: @@ -78,11 +80,11 @@ jobs: # aarch64 is a cross build, so maturin-action runs it in # ghcr.io/rust-cross/manylinux2014-cross:aarch64 rather than the native # quay.io/pypa/manylinux2014_x86_64 image the x86_64 leg uses. That - # cross image's /opt/python stops at CPython 3.14, so --find-interpreter - # never offers 3.15 there -- it reports 3.9 through 3.14, 3.14t and - # PyPy 3.11 and stops. The interpreter itself is present, so naming it - # explicitly works. Without this step aarch64 Linux ships no 3.15 wheel - # at all, which is the gap #404 is about. + # cross image does have 3.15 and 3.15t, but --find-interpreter never + # offers them -- it reports 3.9 through 3.14, 3.14t and PyPy 3.11 and + # stops. Naming them explicitly resolves, so the two steps below build + # them by hand. Without them aarch64 Linux ships no 3.15 wheel at all, + # which is the gap #404 is about. - name: Build the aarch64 CPython 3.15 wheel if: matrix.target == 'aarch64' uses: PyO3/maturin-action@v1 @@ -96,13 +98,10 @@ jobs: env: # Workaround ring 0.17 build issue CFLAGS_aarch64_unknown_linux_gnu: "-D__ARM_ARCH=8" - # Free-threaded 3.15 on aarch64, if the cross image has it. The x86_64 - # leg gets cp315t from the native image; this is the same question asked - # of the cross image, and it is allowed to fail so that a missing 3.15t - # cannot take the cp315 wheel above down with it. + # Free-threaded 3.15 on aarch64. The x86_64 leg gets cp315t from the + # native image; this asks the cross image the same question. - name: Build the aarch64 free-threaded 3.15 wheel if: matrix.target == 'aarch64' - continue-on-error: true uses: PyO3/maturin-action@v1 with: maturin-version: v1.15.0 From 17854b9feff9de23b60d34c7f7614e1855b201ab Mon Sep 17 00:00:00 2001 From: Peefy Date: Mon, 19 Oct 2026 13:49:13 +0800 Subject: [PATCH 7/7] fix(python): declare requires-python >=3.10 protobuf 7.x -- the wheel's only runtime dependency -- requires Python >=3.10, so a 3.9 build of this wheel can never install: pip resolves protobuf, finds no compatible version, and refuses. Declaring >=3.9 let pip believe a 3.9 install was possible and then fail on the dependency rather than up front. The declared floor is now the one that actually works, and it is not a retreat -- the old floor of >=3.7 was already untrue, and the old >=3.9 was untrue for the same reason. maturin skips interpreters below requires-python during --find-interpreter rather than failing, so the Linux images' CPython 3.9 is simply not built any more. The published set goes from 31 wheels to 29: the two cp39 wheels go, and nothing else changes. Signed-off-by: Peefy --- .github/workflows/python-test.yaml | 5 +++-- python/Cargo.toml | 3 ++- python/pyproject.toml | 4 +++- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/python-test.yaml b/.github/workflows/python-test.yaml index e68aa473..d2c843a6 100644 --- a/.github/workflows/python-test.yaml +++ b/.github/workflows/python-test.yaml @@ -50,7 +50,8 @@ jobs: # whatever the image ships plus anything on PATH. That is where the # cp310..cp315 / pp311 spread comes from; there is no version matrix here # and adding one would only duplicate wheels the default build already - # produces. + # produces. Interpreters below `requires-python` are skipped outright -- + # maturin never probes them -- so the 3.9 in the Linux images is not built. # # Linux x86_64 runs in the native manylinux image, which ships 3.9 through # 3.15 (plus free-threaded 3.14t/3.15t and PyPy 3.11), so its cp315 comes @@ -81,7 +82,7 @@ jobs: # ghcr.io/rust-cross/manylinux2014-cross:aarch64 rather than the native # quay.io/pypa/manylinux2014_x86_64 image the x86_64 leg uses. That # cross image does have 3.15 and 3.15t, but --find-interpreter never - # offers them -- it reports 3.9 through 3.14, 3.14t and PyPy 3.11 and + # offers them -- it reports 3.10 through 3.14, 3.14t and PyPy 3.11 and # stops. Naming them explicitly resolves, so the two steps below build # them by hand. Without them aarch64 Linux ships no 3.15 wheel at all, # which is the gap #404 is about. diff --git a/python/Cargo.toml b/python/Cargo.toml index 65dda6bf..9a3ef6d3 100644 --- a/python/Cargo.toml +++ b/python/Cargo.toml @@ -10,5 +10,6 @@ crate-type = ["cdylib"] [dependencies] kcl-api = { git = "https://github.com/kcl-lang/kcl", version = "0.13.2" } # 0.30 is the first line with final Python 3.15 support (0.29 had it as beta). -# It requires Python >=3.9, which is why `requires-python` is not lower. +# It supports Python 3.9, but `requires-python` is 3.10 -- protobuf 7.x, which +# this wheel depends on, needs 3.10 -- so a 3.9 build would be unusable. pyo3 = "0.30" diff --git a/python/pyproject.toml b/python/pyproject.toml index 8bbf3458..8988fca9 100644 --- a/python/pyproject.toml +++ b/python/pyproject.toml @@ -8,7 +8,9 @@ build-backend = "maturin" [project] name = "kcl_lib" version = "0.13.2" -requires-python = ">=3.9" +# protobuf 7.x needs Python >=3.10, so a 3.9 build of this wheel could never +# install. pyo3 0.30 would support 3.9, but that would be a lie. +requires-python = ">=3.10" classifiers = [ "Programming Language :: Rust", "Programming Language :: Python :: Implementation :: CPython",