python-packaging

Package Python projects with pyproject.toml and publish to PyPI.

Updated Apr 4, 2026
One-click install
npx skills add https://github.com/emilneuraz-ai/neuraz-web --skill python-packaging-emilneuraz-ai
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: python-packaging
Source: https://github.com/emilneuraz-ai/neuraz-web/tree/main/.agents/skills/.agents/skills/python-packaging
Command: npx skills add https://github.com/emilneuraz-ai/neuraz-web --skill python-packaging-emilneuraz-ai

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Packaging Python projects for distribution can be complex, requiring a reproducible structure, correct metadata, and a robust publishing workflow to PyPI.

Core Features & Use Cases

  • Modern packaging with pyproject.toml across backends (setuptools, hatchling, flit, poetry) for consistent builds.
  • Support for multiple layouts (source layout under src/, flat layout) and generation of both wheel and source distributions.
  • Publishing workflows to PyPI or private indexes, including TestPyPI testing and metadata validation.

Quick Start

Create a minimal Python package with pyproject.toml and publish it to PyPI.

Frequently Asked Questions about python-packaging

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I package a Python project using pyproject.toml?

To package a Python project using pyproject.toml, configure your build backend metadata and project structure under src/ or flat layouts, then generate wheel and source distributions for PyPI publishing.

What build backends can I use for Python packaging?

Python packaging supports multiple build backends including setuptools, hatchling, poetry, and flit, allowing you to choose the tool that best fits your project structure and dependency management needs.

How do I publish a package to TestPyPI before releasing to PyPI?

Publishing to TestPyPI before PyPI involves configuring your distribution workflow to target the TestPyPI index, validating your package metadata, and then switching to PyPI for the final release.

Does Python packaging support both src and flat layout structures?

Yes, Python packaging supports both src/ and flat layout structures, enabling you to organize your source code flexibly while maintaining reproducible builds and correct metadata generation.

What is the difference between wheel and sdist distributions?

A wheel is a pre-built binary distribution format for faster installation, while an sdist is a source distribution containing the raw source code, and Python packaging generates both formats.

Can I publish Python packages to private indexes instead of PyPI?

Yes, you can configure your publishing workflow to target private package indexes instead of PyPI, allowing for internal distribution while maintaining the same build and metadata standards.