pypi-publish

pypi-publish is a skill for Claude Code from queelius/claude-anvil. It costs 53 tokens per session (2,791 once invoked), scanned B, original, MIT.

A workflow for publishing a Python package to PyPI, the public index where Python packages are distributed. It checks package metadata, runs tests, builds packages, and tests the result on TestPyPI before publication.

In plain words
What is it for?
Use it to prepare a Python package, verify its tests and name, version, README, and dependencies, build distributions, and publish through PyPI.
Why use it?
It reduces mistakes in package configuration and gives a separate test publication step before sending a package to the main index.

Skill for Claude Code

Written for Claude Code: ${CLAUDE_PLUGIN_ROOT} variable.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the pub-pipeline plugin — 6 skills, 5 commands, 5 agents shipped together

Good fit Use it to prepare a Python package, verify its tests and name, version, README, and dependencies, build distributions, and publish through PyPI.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add queelius/claude-anvil
Claude Code
/plugin install pub-pipeline

Made for: Claude Code.

Or install pub-pipeline, the plugin that ships this one along with the rest of its 6 skills, 5 commands, 5 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pypi-publish

README.md
[![agentmods](https://agentmods.dev/badge/skills/queelius/claude-anvil/pypi-publish/github.svg)](https://agentmods.dev/skills/queelius/claude-anvil/pypi-publish)
Your own site
<a href="https://agentmods.dev/skills/queelius/claude-anvil/pypi-publish"><img src="https://agentmods.dev/badge/skills/queelius/claude-anvil/pypi-publish/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for pypi-publish

Your own site · 80×15
<a href="https://agentmods.dev/skills/queelius/claude-anvil/pypi-publish"><img src="https://agentmods.dev/badge/skills/queelius/claude-anvil/pypi-publish.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,791 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00053 $0.02791
Opus 5.5 $0.00021 $0.01116
Sonnet 5.5 $0.00011 $0.00558
Haiku 4.5 $0.00005 $0.00279

Measured today against content hash 7972ce45f63b, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

pypi-publish scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Recursive force deletemediumDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

cd /path/to/package && rm -rf dist/* && python -m build

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

pub-pipeline/skills/pypi-publish/SKILL.md · 268 lines

How it starts

The opening of the file, as written. The whole thing — 268 lines — stays where its author put it; the contents beside it link to each section on GitHub.

PyPI Package Publication

Guide the complete workflow for publishing a Python package to the Python Package Index (PyPI). This skill audits package metadata, verifies tests pass, builds distributions, tests on TestPyPI, and handles the final publication.

Workflow

1. Locate the Package

Identify the Python package to publish. Use Glob tool to search for:

  • pyproject.toml (modern standard)
  • setup.py (legacy)
  • setup.cfg (legacy configuration)

If multiple build configuration files exist, prefer pyproject.toml. If no package configuration is found, ask the user which package to publish.

2. Load User Config

Read .claude/pub-pipeline.local.md if it exists (Read tool). Extract python.pypi_username from YAML frontmatter. If the file is missing, inform the user and offer to create one from the template at ${CLAUDE_PLUGIN_ROOT}/docs/user-config-template.md.

3. Audit Package Metadata

Read the package configuration file(s) and verify all required metadata fields are present and properly formatted.

Required fields (Read tool):

Field Check
name Present, follows PyPI naming rules (lowercase, hyphens/underscores only)
version Present, follows PEP 440 (e.g., "1.0.0", "0.1.0a1")
description Present, concise one-line summary
readme Points to existing README file (README.md, README.rst)
license SPDX license expression string (e.g. "MIT"), per PEP 639; the {text = ...} / {file = ...} table form is deprecated
license-files Globs for license files (e.g. ["LICENSE"]); each must match a file
authors or maintainers At least one with name and email
urls Homepage, documentation, repository, bug tracker
classifiers Development status, intended audience, Python versions. No License :: classifiers (deprecated by PEP 639; build tools may reject them alongside license)
requires-python Minimum Python version; floor it at a non-EOL release (">=3.11" as of 2026-10, when 3.10 reached end of life)

Read the full file on GitHub · 268 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 268 lines · 53 tokens per session scan B 7972ce45f63b

Subscribe to this mod's changes

pypi-publish is a skill published in the GitHub repository queelius/claude-anvil (2 stars, last pushed yesterday), licensed MIT. It adds 53 tokens to every session and 2,791 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it B with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-19.