From 2f27853a14cfc8288e2eb56523fd69c8081c06ff Mon Sep 17 00:00:00 2001 From: Adarsh Prashar Date: Sun, 31 May 2026 18:46:14 +0530 Subject: [PATCH] fix(sdk): include package files in the built wheel MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Python SDK project lives in a repo subdirectory (sdks/python). Hatchling's default VCS-aware file selector lists tracked files relative to the repo root, which don't match the project-root-relative `packages = ["riskkernel"]` include, so the built wheel contained only dist-info — `pip install riskkernel` installed no modules and `import riskkernel` failed. Set `ignore-vcs = true` so hatchling selects files from the filesystem. The wheel now ships all 9 modules and imports cleanly. `make sdk-test` missed this because it runs against the source tree on PYTHONPATH, not an installed wheel. Fixes #32 --- CHANGELOG.md | 6 ++++++ sdks/python/pyproject.toml | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6dd1f9b..42dec15 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,12 @@ surface is governed by [`COMPATIBILITY.md`](COMPATIBILITY.md). ## [Unreleased] +### Fixed +- **Python SDK packaged an empty wheel** — `pip install riskkernel` (and installing + the SDK by path) installed no modules, so `import riskkernel` failed. The project + sits in a repo subdirectory and hatchling's VCS file selector excluded the package + files; selecting from the filesystem (`ignore-vcs`) fixes it. ([#32](https://github.com/prashar32/riskkernel/issues/32)) + ## [0.1.0] - 2026-05-31 The first release: the deterministic reliability runtime for AI agents — diff --git a/sdks/python/pyproject.toml b/sdks/python/pyproject.toml index 45bf4a8..dc306d7 100644 --- a/sdks/python/pyproject.toml +++ b/sdks/python/pyproject.toml @@ -28,5 +28,12 @@ Source = "https://github.com/prashar32/riskkernel" langchain = ["langchain-core"] dev = ["pytest"] +# This project lives in a subdirectory (sdks/python) of the repo. Hatchling's +# VCS-aware file selector lists tracked files relative to the repo root, which +# don't match the project-root-relative `packages` include — so the wheel comes +# out empty. Selecting files from the filesystem instead of git fixes it. (#32) +[tool.hatch.build] +ignore-vcs = true + [tool.hatch.build.targets.wheel] packages = ["riskkernel"]