Skip to content

Prepare and harden publishing for 0.2.0 - #16

Merged
cssho merged 3 commits into
masterfrom
release-prep
Oct 26, 2026
Merged

cssho merged 3 commits into
masterfrom
release-prep

Conversation

@cssho

@cssho cssho commented Oct 26, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Publish trigger release: created → published: created also fires for drafts (possibly uploading before the release is final) and does not fire when a draft is later published
  • sdist contents: add MANIFEST.in — setuptools-scm puts every git-tracked file in the sdist, which currently ships .claude/, .github/, CLAUDE.md, uv.lock
  • Publish workflow split (code review): build job without OIDC runs ruff + pytest, builds, and asserts the built version equals the release tag (a malformed tag like vv0.2.0 makes setuptools-scm fall back to a dev version → fail before upload); publish job only downloads the artifact and uploads with id-token: write
  • Actions pinned to commit SHAs (code review) in both workflows, version in a comment. Side benefit: setup-uv stopped publishing floating major tags after v7, so Dependabot couldn't see v8–v10 while we used @v7
  • /release: quote the YAML description (it contained : and broke the frontmatter), add argument-hint, normalize the version (strip one leading v, require X.Y.Z > latest tag), document the approval step
  • CLAUDE.md documents the pypi environment approval and v* tag protection (repo settings applied separately)

Test plan

  • uv build → sdist has only md_condition/, tests/, README.md, LICENSE, pyproject.toml, MANIFEST.in + metadata; twine check --strict PASSED
  • Version check simulated locally (SETUPTOOLS_SCM_PRETEND_VERSION=0.2.0): passes for v0.2.0, fails for vv0.2.0
  • Workflow and skill frontmatter YAML parse
  • CI green (the publish workflow itself only runs on release)

🤖 Generated with Claude Code

https://claude.ai/code/session_012pKTVb5TrGn27R29rHHNck

cssho and others added 3 commits October 26, 2026 21:47
- Publish on `release: published` instead of `created`, so drafts
  don't upload and publishing a draft does
- MANIFEST.in: keep .claude/, .github/, CLAUDE.md, uv.lock out of
  the sdist (setuptools-scm includes every tracked file)
- Document the pypi environment approval and tag protection in
  CLAUDE.md and /release

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012pKTVb5TrGn27R29rHHNck
- Pin every action to a commit SHA (version in a comment). Also lets
  Dependabot see setup-uv >= v8, which no longer has floating major tags
- Publish workflow: build job (no OIDC) runs lint + tests, builds, and
  checks the built version equals the release tag; publish job only
  downloads the artifact and uploads with id-token: write
- /release: normalize the version (strip one leading v, require X.Y.Z
  greater than the latest tag) so `/release v0.2.0` can't tag vv0.2.0

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012pKTVb5TrGn27R29rHHNck
@cssho cssho changed the title Prepare publishing for 0.2.0 Prepare and harden publishing for 0.2.0 Oct 26, 2026
@cssho
cssho merged commit b2fb79a into master Oct 26, 2026
8 checks passed
@cssho
cssho deleted the release-prep branch October 26, 2026 13:12
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