fix: fix set-commits --auto, document release workflow pitfalls#650
Merged
Conversation
Contributor
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. Bug Fixes 🐛
Internal Changes 🔧
🤖 This preview updates automatically when you update the PR. |
657cabd to
9e682d4
Compare
Contributor
Codecov Results 📊✅ 134 passed | Total: 134 | Pass Rate: 100% | Execution Time: 0ms 📊 Comparison with Base Branch
✨ No test changes detected All tests are passing successfully. ✅ Patch coverage is 95.65%. Project has 1373 uncovered lines. Files with missing lines (1)
Coverage diff@@ Coverage Diff @@
## main #PR +/-##
==========================================
+ Coverage 95.64% 95.65% +0.01%
==========================================
Files 219 219 —
Lines 31550 31569 +19
Branches 0 0 —
==========================================
+ Hits 30176 30196 +20
- Misses 1374 1373 -1
- Partials 0 0 —Generated by Codecov Action |
9e682d4 to
87d43f5
Compare
Contributor
|
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
87d43f5 to
d33b007
Compare
- Rewrite setCommitsAuto: list org repos via paginated API, match against local git remote, fetch previous release commit for range, send real refs with HEAD SHA and previousCommit - Use ValidationError for local git failures, ApiError for no-repos - Catch ValidationError in setCommitsDefault for graceful fallback - Add checkout, setup-node@v6, environment: production to workflow - Move --url from release create to deploy step - Add workflow_dispatch trigger and failure issue creation - Document pitfalls in agent-guidance.md, release.md, help text - Regenerate SKILL.md and reference files - Add comprehensive tests for all code paths
d33b007 to
0a4e466
Compare
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
Fixes
set-commits --autoto properly discover commits and documents release workflow pitfalls learned from shipping the sentry-release CI workflow.Continuation of #643, #645, #648, #649 (all merged).
Changes
set-commits --autorewrite (src/lib/api/releases.ts){repository: "auto", commit: "auto"}— list org repos via paginated API, match against local git remote, send real refs with HEAD SHA/previous-with-commits/endpoint so Sentry can compute the commit range (without this, 0 commits are reported)listRepositoriesPaginated)ApiErrorfor no-repos (correct negative caching),ValidationErrorfor local git failuresApiErrorconstructor:endpointas 4th arg, not 3rdFallback fix (
src/commands/release/set-commits.ts)ValidationErrorinsetCommitsDefault→ fall back to local git historyWorkflow fixes (
.github/workflows/sentry-release.yml)actions/checkout@v6withfetch-depth: 0(needed for--autogit discovery)--urlfromrelease createtorelease deploy(URL belongs on the deploy)Documentation
--autowithout checkoutorg/versionpositional format and version matching--autorequires git checkout; documents default fallback behaviorTests
--autocwd pass-through,ValidationErrorfallback in default modereleases.ts~99%,set-commits.ts~75%