Skip to content

Conversation

@jpchauvel
Copy link
Contributor

@jpchauvel jpchauvel commented Sep 5, 2025

Summary by CodeRabbit

  • New Features

    • Added a public CLI command: edit-python-pe.
  • Tests

    • Test coverage now resets on each run for accurate per-run reporting.
  • Chores

    • Bumped version to 0.2.3.
    • Updated deployment workflow naming and publish checks.
    • Introduced pre-commit hooks for testing and automated version bumping.
    • Added Repository URL and modernized license metadata.
    • Standardized code style configuration (Black, line length 79).
    • Updated development dependencies (including pre-commit and TOML writer).

@coderabbitai
Copy link

coderabbitai bot commented Sep 5, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

Renames the GitHub Actions job, augments the uv publish command with a URL check, introduces a pre-commit config with local hooks, adds a version-bumping Python script, tweaks the test script’s pytest-cov options, and updates pyproject metadata including version, classifiers, URLs, dev dependencies, build-system layout, Black config, and a console script entry point.

Changes

Cohort / File(s) Summary of changes
CI publish workflow
.github/workflows/publish.yml
Job name changed from "docs" to "deploy". Publish step adds --check-url https://pypi.org/simple to uv publish alongside --managed-python.
Pre-commit setup
.pre-commit-config.yaml
New pre-commit config with default stage pre-push. Adds two local hooks: testing (runs ./bin/test.sh) and bumping-version (runs uv run ./bin/bump-version.py).
Release/version tooling
bin/bump-version.py
New script: reads uv.lock and pyproject.toml, bumps final numeric segment of version for package "edit-python-pe", writes back, stages files, and commits with "Bump version". Uses tomllib, tomli_w, and subprocess.
Test runner
bin/test.sh
Adds --cov-reset to pytest invocation to reset coverage data each run.
Project metadata and tooling
pyproject.toml
Version bumped 0.2.1 → 0.2.3. Adds [project.license] with file, refines classifiers, adds Repository URL, defines console script edit-python-pe = "edit_python_pe.main:main", adjusts [build-system] requires format, adds [tool.black], and adds dev deps pre-commit and tomli-w.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor Developer
  participant Git as Git
  participant PreCommit as Pre-commit (pre-push)
  participant Test as ./bin/test.sh
  participant Bump as uv run bump-version.py

  Developer->>Git: git push
  Git->>PreCommit: Trigger pre-push hooks
  PreCommit->>Test: Execute tests (pytest --cov ... --cov-reset)
  alt tests pass
    PreCommit->>Bump: Execute version bump
    Bump->>Bump: Read uv.lock, pyproject.toml
    Bump->>Bump: Increment version (final numeric segment)
    Bump->>Bump: Write pyproject.toml, uv.lock
    Bump->>Git: git add pyproject.toml uv.lock
    Bump->>Git: git commit -m "Bump version"
  else tests fail
    PreCommit-->>Developer: Abort push with test failures
  end
Loading
sequenceDiagram
  autonumber
  participant GitHub as GitHub Actions
  participant Job as deploy job
  participant Uv as uv publish

  GitHub->>Job: On workflow trigger
  Job->>Uv: uv publish --managed-python --check-url https://pypi.org/simple [...]
  Uv-->>Job: Publish result
  Job-->>GitHub: Job status
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Poem

I nudge the version, hop by hop,
Reset the tracks so tests don’t flop.
A push, a pre-commit—thump, thump—away!
The deploy burrow hums today.
With tidy TOML, scripts set free,
I twitch my nose at 0.2.3. 🐇✨


📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 9700307 and cb1f6b6.

⛔ Files ignored due to path filters (1)
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing (5)
  • .github/workflows/publish.yml (2 hunks)
  • .pre-commit-config.yaml (1 hunks)
  • bin/bump-version.py (1 hunks)
  • bin/test.sh (1 hunks)
  • pyproject.toml (3 hunks)
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch hotfix

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbitai help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbitai ignore or @coderabbit ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@jpchauvel jpchauvel closed this Sep 5, 2025
@jpchauvel jpchauvel deleted the hotfix branch September 5, 2025 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants