Repository navigation
feat: Phase 7 — PR summaries, release changelogs, and unified orchestrator - #12
Merged
Merged
Conversation
…d orchestrator consolidation - #1 (Blocker): Fail loud with exit code 1 on git errors, budget cap breaches, and gh CLI errors across pr-summary and changelog CLI commands. - #2: Prevent duplicate printing when no changes/commits exist by early returning None. - #3: Route diagnostic warnings, budget alerts, and error messages to stderr console (err_console) to keep stdout clean for Unix piping. - #4: Correctly parse and surface breaking changes (exclamation mark and BREAKING CHANGE: footers) in conventional commits and templates. - #5: Bump changelog template to version 2, including from_ref..to_ref range and explicit release headers. - #6: Support --title (-t) flag in pr-summary and propagate gh pr create failures. - #7: Remove dead head argument from fallback PR summary. - #8: Consolidate duplicate budget checking, safe telemetry recording, and heuristic token counters into orchestrator.py. - #9: Enforce strict type hints with CommitLogEntry in fallback.py.
Owner
Author
Review Feedback Resolutions & FixesThank you for the rigorous review! All findings from the review have been addressed in commit 1. Blocker: Fail loud with Exit Code 1 on Errors (
|
… breaking change footers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Phase 7 extends
gitmatebeyond single-commit generation with two daily-use capabilities:gitmate pr-summary: Compares the current branch against a base branch (mainby default), extracts the 3-dot diff (base...HEAD), applies token budgeting & chunking, and generates a structured GitHub Markdown PR description. Automatically copies the description to the system clipboard (pyperclip) and optionally triggers the GitHub CLI PR creation flow (--create-pr).gitmate changelog: Walks git commit history between two tags/refs (--fromand--to), categorizes commits using conventional-commit rules (Features,Bug Fixes,Performance & Refactoring,Documentation,Maintenance & Tooling, andOther Changesfallback bucket for zero lost commits), synthesizes them with optional file diff notes, and outputs directly tostdout(Unix pipe friendly) or to an output file (-o/--output).gitmate.orchestrator.run_generation_pipelinereused acrosscommit,pr-summary, andchangelog.Changes
src/gitmate/orchestrator.py: Centralized LLM pipeline handling token budgeting, chunking of omitted diffs, caching, provider calls, cost calculation, and fallback.src/gitmate/prompt.py: Added genericrender_promptand alias forchangelogtemplate.src/gitmate/templates/changelog.txt: Versioned prompt template for release changelogs.src/gitmate/fallback.py: Refactoredgenerate_commit_messageto delegate torun_generation_pipeline; addedgenerate_fallback_pr_summaryandgenerate_fallback_changelog.src/gitmate/pr_summary.py: Full PR summary generation pipeline, headless-resilient clipboard handling, and optionalgh pr createdispatch.src/gitmate/changelog.py:CommitLogEntrydataclass, conventional-commit parser, semantic category grouping, stdout/file output handling.src/gitmate/cli.py: Implemented realpr-summaryandchangelogcommands.command="pr_summary"" andcommand="changelog"" wired intometrics.db.tests/test_pr_summary.py: Branch comparison, mock provider, clipboard fallback, gh CLI handling, budget cap abort, telemetry recording.tests/test_changelog.py: Conventional commit parsing, grouping, real git tag extraction, file output, telemetry recording.tests/test_cli.py: CLI integration tests forpr-summaryandchangelog.Verification
uv run pytest: 253 passed in 13s (0 regressions, 22 new tests).uv run ruff check .: 0 errors / clean.uv run ruff format --check .: 35 files clean.uv run mypy src tests: strict mode clean across 32 source files.