Skip to content

Ship complete sdist, add release verification gate, prep 3.2.3#62

Merged
elijahr merged 4 commits into
masterfrom
fix/sdist-completeness
Jun 5, 2026
Merged

Ship complete sdist, add release verification gate, prep 3.2.3#62
elijahr merged 4 commits into
masterfrom
fix/sdist-completeness

Conversation

@elijahr

@elijahr elijahr commented Jun 5, 2026

Copy link
Copy Markdown
Owner

Fixes the incomplete PyPI sdist: 3.2.2's tarball omitted the test helper modules (test/assertions.py, test/cython_utils.py, test/conftest.py, and others) and data dirs (test/fixtures/, test/real_headers/, test/regressions/), so downstream packagers running tests from the sdist hit ModuleNotFoundError: No module named 'test.assertions' at collection.

What's here:

  • MANIFEST.in — explicit sdist spec: full test/ tree, scripts/, top-level docs. The sdist now mirrors git ls-files (verified: 97/97 tracked test files present; pytest --collect-only on the extracted sdist collects with 0 errors).
  • Ship-guardcheck-manifest and twine check --strict run in the publish workflow's build job between build and artifact upload; publish-pypi has needs: build, so a failed gate blocks publishing on both triggers (release and workflow_dispatch). Tool versions pinned (check-manifest==0.51, twine==6.2.0). An advisory check-manifest pre-commit hook (rev 0.51, --no-build-isolation) runs locally and in PR CI; it carries additional_dependencies: [setuptools, wheel] because with --no-build-isolation the hook env must supply the build backend — a deliberate addition beyond the original design notes.
  • Wheel fix (intentional wheel change)autopxd/stubs/darwin-include/.supports-builtin-modules is tracked in git and lives in the runtime clang include tree, but the stubs/darwin-include/**/* package-data glob skips leading-dot files, so it was missing from every previous wheel. It now ships in both wheel and sdist. This supersedes the working design's "wheel untouched" assumption: the 3.2.3 wheel intentionally gains exactly this one file vs 3.2.2.
  • Release prep — version 3.2.3; Keep-a-Changelog entry, including a note that downstream packagers without network access must deselect the real_headers tests (pytest -m "not real_headers"); CHANGELOG footer compare-links retargeted and backfilled; CONTRIBUTING gains a ship-guard subsection and a warning that the workflow_dispatch ref must contain the version bump.
  • Build floorbuild-system.requires pinned to setuptools>=61 (PEP 621 [project] metadata floor).

Local verification: check-manifest exit 0; twine check --strict PASSED for both artifacts; wheel file-list diff vs the 3.2.2 baseline shows exactly the one intended added file; targeted pytest subset 49/49 passing on the bumped package; negative controls confirm the gate actually fails on injected manifest breakage.

After merge: create the GitHub Release v3.2.3 from a ref containing the version bump (per CONTRIBUTING); the publish workflow builds, gates, and publishes.

elijahr added 2 commits June 5, 2026 17:25
- Add MANIFEST.in so the sdist includes the full test tree (helpers, fixtures, real_headers, regressions), scripts/, and docs needed to run the suite from the tarball

- Ship autopxd/stubs/darwin-include/.supports-builtin-modules in both wheel and sdist (package-data globs skip leading-dot files)

- Gate publishing on check-manifest and twine check --strict in the build job; add check-manifest pre-commit hook

- Pin build-system setuptools>=61; bump version to 3.2.3 with changelog entry and release-process docs

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request configures check-manifest and introduces a MANIFEST.in file to ensure the complete test suite and necessary runtime stubs (specifically .supports-builtin-modules) are included in the source distribution (sdist) and wheel. It also updates the changelog, contributing guidelines, and build requirements in pyproject.toml. The review feedback suggests using the graft command in MANIFEST.in for the test and scripts directories to make inclusion more robust, and aligning the setuptools version requirement in the pre-commit configuration with pyproject.toml.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread MANIFEST.in Outdated
Comment thread MANIFEST.in Outdated
Comment thread .pre-commit-config.yaml
- Use graft for test/ and scripts/ instead of extension allowlists,
  with global-exclude for *.py[cod] and __pycache__
- Pin setuptools>=61 in check-manifest hook deps to match the
  build-system floor
@elijahr

elijahr commented Jun 5, 2026

Copy link
Copy Markdown
Owner Author

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request prepares the project for the 3.2.3 release by resolving packaging issues. It ensures that the complete test suite and the hidden runtime stub .supports-builtin-modules are correctly included in both the source distribution (sdist) and wheel. This is achieved by adding a MANIFEST.in file, updating package data in pyproject.toml, and integrating check-manifest into the pre-commit hooks and release documentation. Feedback suggests removing the redundant and ineffective global-exclude __pycache__ directive from MANIFEST.in, as compiled Python files are already handled by the preceding rule.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread MANIFEST.in Outdated
global-exclude matches file paths, not directories; *.py[cod]
already excludes the byte-compiled files inside __pycache__.
@elijahr

elijahr commented Jun 5, 2026

Copy link
Copy Markdown
Owner Author

/gemini review

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request prepares the project for the 3.2.3 release by addressing packaging completeness issues. It introduces a MANIFEST.in file to ensure the full test suite and the runtime stub .supports-builtin-modules are included in the source distribution (sdist) and wheel. Additionally, it integrates check-manifest into the pre-commit configuration and pyproject.toml to prevent future incomplete distributions, updates the changelog and contributing guidelines, and bumps the version to 3.2.3. There are no review comments, so no further feedback is provided.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@elijahr elijahr merged commit dfb9857 into master Jun 5, 2026
12 checks passed
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