From 91b48c13738cc763fc2562156aeadc8111086989 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 17:39:07 +0900 Subject: [PATCH 1/8] Upgrade PyO3 to 0.26.0 --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 30e6e2a..8e669cc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,7 @@ name = "tossicat" crate-type = ["cdylib"] [dependencies] -pyo3 = { version = "0.22.6", features = ["extension-module"] } +pyo3 = { version = "0.26.0", features = ["extension-module"] } tossicat = "0.6.1" [package.metadata.maturin] From a2bda6bed508b7565fff13e511792d596e2841c9 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 17:39:53 +0900 Subject: [PATCH 2/8] Build 3.14 wheels on GitHub Actions --- .github/workflows/deploy.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index c594ba7..6bf4e2e 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -12,7 +12,7 @@ jobs: with: manylinux: auto command: build - args: --release --sdist -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 pypy3.10 + args: --release --sdist -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 pypy3.10 - name: Upload wheels uses: actions/upload-artifact@v3 with: @@ -26,7 +26,7 @@ jobs: - uses: PyO3/maturin-action@v1 with: command: build - args: --release -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 + args: --release -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 - name: Upload wheels uses: actions/upload-artifact@v3 with: @@ -40,7 +40,7 @@ jobs: - uses: PyO3/maturin-action@v1 with: command: build - args: --release -o dist --target universal2-apple-darwin -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 pypy3.10 + args: --release -o dist --target universal2-apple-darwin -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 pypy3.10 - name: Upload wheels uses: actions/upload-artifact@v3 with: From b1e886b31070ad58447d6b29503550fcf18c3d98 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 17:42:24 +0900 Subject: [PATCH 3/8] Update GitHub Actions deps --- .github/workflows/deploy.yml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 6bf4e2e..4af6ef2 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -7,14 +7,14 @@ jobs: linux: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v5 - uses: PyO3/maturin-action@v1 with: manylinux: auto command: build args: --release --sdist -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 pypy3.10 - name: Upload wheels - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: wheels path: dist @@ -22,13 +22,13 @@ jobs: windows: runs-on: windows-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v5 - uses: PyO3/maturin-action@v1 with: command: build args: --release -o dist -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 - name: Upload wheels - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: wheels path: dist @@ -36,13 +36,13 @@ jobs: macos: runs-on: macos-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v5 - uses: PyO3/maturin-action@v1 with: command: build args: --release -o dist --target universal2-apple-darwin -i 3.7 3.8 3.9 3.10 3.11 3.12 3.13 3.14 pypy3.10 - name: Upload wheels - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: wheels path: dist @@ -52,7 +52,7 @@ jobs: runs-on: ubuntu-latest needs: [ macos, windows, linux ] steps: - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v5 with: name: wheels - name: Publish to PyPI From 5f0a6d7a9fa9834bf68e0650eaae7b8889c5a4f9 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 17:56:18 +0900 Subject: [PATCH 4/8] Add generate-import-lib feature of PyO3 for windows build --- Cargo.toml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 8e669cc..67ee9fc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,10 @@ name = "tossicat" crate-type = ["cdylib"] [dependencies] -pyo3 = { version = "0.26.0", features = ["extension-module"] } +pyo3 = { version = "0.26.0", features = [ + "extension-module", + "generate-import-lib", +] } tossicat = "0.6.1" [package.metadata.maturin] From 3af75aa735594dc846d7e871029b1625726d4120 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 17:57:06 +0900 Subject: [PATCH 5/8] Update usage of up/download artifacts --- .github/workflows/deploy.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 4af6ef2..5cbad6b 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -16,7 +16,7 @@ jobs: - name: Upload wheels uses: actions/upload-artifact@v4 with: - name: wheels + name: wheels-linux path: dist windows: @@ -30,7 +30,7 @@ jobs: - name: Upload wheels uses: actions/upload-artifact@v4 with: - name: wheels + name: wheels-windows path: dist macos: @@ -44,7 +44,7 @@ jobs: - name: Upload wheels uses: actions/upload-artifact@v4 with: - name: wheels + name: wheels-macos path: dist release: @@ -54,7 +54,9 @@ jobs: steps: - uses: actions/download-artifact@v5 with: - name: wheels + path: dist + pattern: wheels-* + merge-multiple: true - name: Publish to PyPI uses: PyO3/maturin-action@v1 env: From 39363b62a7488ce1c575abcbac9f68e10763c284 Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 18:00:40 +0900 Subject: [PATCH 6/8] Set version of pyproject as dynamic metadata --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 48b318a..37c2beb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,3 +13,4 @@ classifiers = [ "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", ] +dynamic = ["version"] From e8225b300ad4f9c5cfa150d28e6cc2a114ef9b2a Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 18:07:34 +0900 Subject: [PATCH 7/8] Add more metadata on pyproject.toml --- pyproject.toml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 37c2beb..1ecd9c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,7 @@ requires = ["maturin>=1.0,<2.0"] build-backend = "maturin" [tool.maturin] -features = ["pyo3/extension-module"] +features = ["pyo3/extension-module", "pyo3/generate-import-lib"] [project] name = "tossicat-python" @@ -14,3 +14,8 @@ classifiers = [ "Programming Language :: Python :: Implementation :: PyPy", ] dynamic = ["version"] +readme = "README.md" +license = { file = "LICENSE" } + +[project.urls] +repository = "https://github.com/tossicat/tossicat-python" From e8975671a74b26aa9e5cea0a4ee542f87114b4ba Mon Sep 17 00:00:00 2001 From: Kim Jinsu Date: Thu, 9 Oct 2025 18:22:19 +0900 Subject: [PATCH 8/8] Mark as typed this project --- Cargo.toml | 2 +- py.typed | 0 pyproject.toml | 6 ++++-- 3 files changed, 5 insertions(+), 3 deletions(-) create mode 100644 py.typed diff --git a/Cargo.toml b/Cargo.toml index 67ee9fc..8a1ccc2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -16,4 +16,4 @@ pyo3 = { version = "0.26.0", features = [ tossicat = "0.6.1" [package.metadata.maturin] -include = ["tossicat.pyi"] +include = ["tossicat.pyi", "py.typed"] diff --git a/py.typed b/py.typed new file mode 100644 index 0000000..e69de29 diff --git a/pyproject.toml b/pyproject.toml index 1ecd9c1..2103389 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,10 +12,12 @@ classifiers = [ "Programming Language :: Rust", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", + "Typing :: Typed", ] dynamic = ["version"] readme = "README.md" -license = { file = "LICENSE" } +license = "LGPL-2.1" +license-files = ["LICENSE"] [project.urls] -repository = "https://github.com/tossicat/tossicat-python" +"Source Code" = "https://github.com/tossicat/tossicat-python"