Skip to content

fix(install): cap requires-python<3.14, add Windows smoke matrix, fix path bug#43

Merged
szjanikowski merged 1 commit into
mainfrom
fix/python-313-cap-and-windows-smoke
May 8, 2026
Merged

fix(install): cap requires-python<3.14, add Windows smoke matrix, fix path bug#43
szjanikowski merged 1 commit into
mainfrom
fix/python-313-cap-and-windows-smoke

Conversation

@szjanikowski
Copy link
Copy Markdown
Contributor

Summary

  • v0.3.2 fails to install on Windows + Python 3.14 because the transitive dep pyiceberg (via supabasestorage3) has no cp314 wheels and source build needs MSVC. Linux-only smoke on 3.12 masked it.
  • Cap requires-python<3.14, document --python 3.13 in README, expand smoke test matrix to [ubuntu, windows] × [3.12, 3.13].
  • Fix a real Windows-only path bug in runner.py — sandbox keys for codex/gemini skills had backslashes ('/app/.gemini/skills/x\SKILL.md'), breaking sandbox_files mapping at runtime.

Why this works

Concern Resolution
pyiceberg no cp314 wheels requires-python<3.14 declares it (honored by pip / uv pip / poetry / dependabot)
uv tool install ignores requires-python at interpreter selection README now passes --python 3.13 explicitly; smoke test matrix exercises the same command path
Linux-only CI hides Windows breakage Matrix [ubuntu, windows] × [3.12, 3.13] = 4 jobs (free for public repos)
Path bug in runner.py relative.as_posix() before f-string interpolation

Test plan

  • uv sync clean on 3.13
  • uv run nasde --version works
  • ruff check, ruff format --check, mypy all green
  • pytest — 145 pass, 2 fail (both pre-existing Windows-only test isolation issues, see follow-up)
  • uv tool install . --python 3.13 --reinstall --force succeeds locally on Windows
  • uv tool install ./nasde-toolkit --python 3.13 from parent dir succeeds
  • CI smoke test goes green on all 4 matrix combinations (verifying after merge)

Out of scope (follow-up)

Tracked separately — see issue for "Windows quality-gate matrix" (variant 3 of the discussion):

  • test_codex_backend_validate_auth_succeeds_with_chatgpt_oauth — fails on Windows because the test relies on ~/.codex/auth.json not being present, but doesn't fixture-mock it
  • test_codex_backend_env_strips_api_keys_when_oauth_present — fails when CODEX_API_KEY exists in the developer's real shell (test isolation: missing monkeypatch.delenv)
  • Adding windows-latest to quality-gate.yml matrix to catch these on CI

🤖 Generated with Claude Code

… Windows path bug

The published v0.3.2 fails to install on Windows + Python 3.14 because the
transitive dep `pyiceberg` (via supabase → storage3) ships no cp314 wheels and
falls back to source build, which requires MSVC. Linux smoke test on 3.12
masked this — manylinux wheels are always available.

Changes:

- `pyproject.toml`: cap `requires-python<3.14`. Lift when pyiceberg ships
  cp314 wheels.
- `.python-version`: pin dev shells to 3.13 so `uv run` in the repo
  matches the supported range.
- `README.md`: install commands now pass `--python 3.13`. Added a "Python
  version" note explaining 3.12/3.13 support and the 3.14 gap.
- `.github/workflows/publish.yml`: smoke test matrix
  `[ubuntu-latest, windows-latest] × [3.12, 3.13]`, switched from
  `uv venv + uv pip install` to `uv tool install --python` so CI exercises
  the same command path the README hands to users.
- `src/nasde_toolkit/runner.py`: in `_collect_codex_skills` and
  `_collect_gemini_skills`, call `.as_posix()` on the relative path before
  building sandbox keys. On Windows `Path.__str__` produces backslashes,
  yielding broken sandbox_files keys like
  `'/app/.gemini/skills/x\SKILL.md'`. Linux/macOS unaffected.

Pre-existing Windows-only test failures NOT addressed here (follow-up):
- `test_codex_backend_validate_auth_succeeds_with_chatgpt_oauth`
- `test_codex_backend_env_strips_api_keys_when_oauth_present`
Both are test-isolation issues (real env leakage, missing fixtures), not
production bugs.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@szjanikowski szjanikowski merged commit b29b005 into main May 8, 2026
6 checks passed
szjanikowski added a commit that referenced this pull request May 8, 2026
…lation (#44)

Linux-only quality-gate hid three Windows-only test failures on main. The
runner-test bug was fixed in #43; the remaining two were `Path.home()`
isolation gaps in `tests/test_evaluator_backends.py`: setting `HOME` does not
redirect `Path.home()` on Windows (which reads `USERPROFILE`), so
`_has_chatgpt_oauth()` leaked into the dev's real `~/.codex/auth.json` and
flipped the strip/promote branches in `_build_env`.

- `tests/test_evaluator_backends.py`: replace `monkeypatch.setenv("HOME", ...)`
  with `monkeypatch.setattr("pathlib.Path.home", lambda: tmp_path)` in the
  five codex-oauth tests. Matches the pattern already used in
  `tests/test_runner.py:315,398`. Cross-platform; tests no longer touch
  real env state.
- `.github/workflows/quality-gate.yml`: pytest job now runs on
  `[ubuntu-latest, windows-latest] × ["3.12", "3.13"]` with
  `fail-fast: false`. Lint/typecheck/audit stay single-OS — pure-Python
  checks with no platform variance.

Verified locally on Windows: all 147 tests pass.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
szjanikowski added a commit that referenced this pull request May 9, 2026
* docs(changelog): record Windows compat + skill bundling under [Unreleased]

Captures everything that landed since v0.3.2 (PRs #42, #43, #44, #45) so
the release notes are queued up. Keeps the section under [Unreleased]
deliberately — more fixes are still expected before cutting v0.3.3, and
release docs say the version header should be added at release-cut time.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(changelog): record .gitattributes LF enforcement (#47)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(changelog): record harbor[cloud] dependency switch (#48)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* chore: release v0.3.3

Cuts v0.3.3 from the accumulated [Unreleased] section. Patch bump
(pre-1.0 policy): no breaking changes to user-facing CLI, nasde.toml
schema, or benchmark project layout — Windows compat, OAuth-script
bundling, harbor[cloud] dep switch are all transparent to users.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Szymon Janikowski <szymon.janikowski@itlibrium.com>
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@szjanikowski szjanikowski deleted the fix/python-313-cap-and-windows-smoke branch May 9, 2026 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant