Skip to content

Add pyproject and documentation#1

Merged
leynos merged 2 commits intomainfrom
codex/add-pyproject.toml-and-readme.md
Jun 8, 2025
Merged

Add pyproject and documentation#1
leynos merged 2 commits intomainfrom
codex/add-pyproject.toml-and-readme.md

Conversation

@leynos
Copy link
Copy Markdown
Owner

@leynos leynos commented Jun 8, 2025

Summary

  • configure project metadata in pyproject.toml
  • add a basic README
  • expose a nixie console script
  • declare package version

Testing

  • ruff format --quiet
  • ruff check --quiet
  • pyright
  • pytest -q

https://chatgpt.com/codex/tasks/task_e_6845f4f600ac8322bda1f15fd248a8bf

Summary by Sourcery

Configure packaging via pyproject.toml, set up the console script, declare the package version, refactor the CLI entry point, and add a README

New Features:

  • Add pyproject.toml for project metadata, dependencies, and build configuration
  • Expose the nixie console script entry point via project scripts
  • Declare and expose the package version constant

Enhancements:

  • Refactor CLI entry logic into a dedicated cli() function

Documentation:

  • Add a basic README with usage and development instructions

@sourcery-ai
Copy link
Copy Markdown
Contributor

sourcery-ai Bot commented Jun 8, 2025

Reviewer's Guide

This PR establishes project packaging and documentation by configuring metadata in pyproject.toml, defining the nixie console script entry point, declaring the package version, and adding a comprehensive README with usage and development instructions.

Sequence Diagram for nixie Console Script Execution

sequenceDiagram
    actor User
    participant OS_Shell as "OS/Shell"
    participant nixie_cli as "nixie.cli"

    User->>OS_Shell: executes `nixie <args>`
    activate OS_Shell
    OS_Shell->>nixie_cli: invokes cli() function (via pyproject.toml script config)
    deactivate OS_Shell
    activate nixie_cli
    nixie_cli->>nixie_cli: parsed_args = parse_args()
    nixie_cli->>nixie_cli: exit_code = asyncio.run(main(parsed_args.paths, parsed_args.concurrency))
    nixie_cli-->>User: returns exit_code
    deactivate nixie_cli
Loading

File-Level Changes

Change Details Files
Refactor CLI entry point to support console script
  • Introduce cli() function wrapping parse_args and main invocation
  • Update __main__ guard to call cli() instead of inline code
nixie/cli.py
Declare package version and export API
  • Add module docstring
  • Define __version__ = "0.1.0"
  • Set __all__ to expose version attribute
nixie/__init__.py
Configure project metadata and build via pyproject.toml
  • Add project metadata (name, version, description, authors, license, classifiers)
  • Define optional dev dependencies and console script entry
  • Specify build-system requirements and enable uv integration
pyproject.toml
Add user and developer documentation
  • Provide project overview and CLI usage examples
  • Explain concurrency option and external Node.js dependency
  • Document development setup with uv sync and test tools
README.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @leynos - I've reviewed your changes and they look great!

Here's what I looked at during the review
  • 🟡 General issues: 1 issue found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Comment thread README.md Outdated
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant