Skip to content

Refactor examples to use PEP 723 inline script metadata #1733

Description

@maxisbey

Summary

Simplify the examples directory by using PEP 723 inline script metadata instead of individual pyproject.toml files per example.

Motivation

  • Current examples are verbose - each needs its own pyproject.toml, directory structure, and __main__.py
  • This adds friction for users trying to understand or copy examples
  • PEP 723 (supported by uv run) allows dependencies to be declared inline in a single script file

Goal

Examples that are single self-contained .py files runnable with uv run example.py, making them easier to read, copy, and adapt.


AI Disclaimer

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1Significant bug affecting many users, highly requested featureenhancementRequest for a new feature that's not currently supportedv2Affects the v2 line (2.x on main)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions