Prepare and execute a Python package release with verification steps. Use for releasing Python packages with uv and ruff.
View on GitHubFebruary 1, 2026
Select agents to install to:
npx add-skill https://github.com/sequenzia/claude-alchemy/blob/main/claude-tools/dev-tools/skills/release/SKILL.md -a claude-code --skill releaseInstallation paths:
.claude/skills/release/# Python Release Manager
Execute a complete pre-release workflow for Python packages using `uv` and `ruff`. This command automates version calculation, changelog updates, and tag creation.
## Arguments
- `$ARGUMENTS` - Optional version override (e.g., `1.0.0`). If not provided, version is calculated from changelog entries.
## Workflow
Execute these 9 steps in order. **Fail fast**: Stop immediately if any verification step fails.
---
### Step 1: Pre-flight Checks
Run these checks and stop if any fail:
```bash
# Check current branch
git branch --show-current
```
- **Must be on `main` branch**. If not, stop and report: "Release must be run from the main branch. Currently on: {branch}"
```bash
# Check for uncommitted changes
git status --porcelain
```
- **Must have clean working directory**. If output is not empty, stop and report: "Working directory has uncommitted changes. Please commit or stash them first."
```bash
# Pull latest changes
git pull origin main
```
- Report any merge conflicts and stop if they occur.
---
### Step 2: Run Tests
Execute the test suite:
```bash
uv run pytest
```
- If tests fail, stop and report the failure output
- If tests pass, report: "All tests passed"
---
### Step 3: Run Linting
Execute linting checks:
```bash
uv run ruff check
```
```bash
uv run ruff format --check
```
- If either command fails, stop and report the issues
- If both pass, report: "Linting and formatting checks passed"
---
### Step 4: Verify Build
Build the package:
```bash
uv build
```
- If build fails, stop and report the error
- If build succeeds, report: "Package builds successfully"
---
### Step 5: Changelog Update Check
All verification checks have passed. Before calculating the version, offer to run the changelog-agent to ensure the `[Unreleased]` section is up-to-date.
Use AskUserQuestion:
```
Would you like to run the changelog-agent to update CHANGELOG.md before proceeding?
This will analyze git commits since the last release an