refactor: drop auto-detection of stacked PRs / local stacks#478
Merged
tomasz-tomczyk merged 1 commit intomainfrom May 7, 2026
Merged
refactor: drop auto-detection of stacked PRs / local stacks#478tomasz-tomczyk merged 1 commit intomainfrom
tomasz-tomczyk merged 1 commit intomainfrom
Conversation
Auto-promotion into range mode is workflow-dependent: branching off a long-lived parent looks identical to a stacked PR from the branch graph, so detection misfires for non-stacking workflows. Make stack review explicit via --pr / --range; remove the --working-tree bypass that only existed to escape the auto-promote. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #478 +/- ##
==========================================
+ Coverage 69.12% 69.24% +0.12%
==========================================
Files 36 35 -1
Lines 10736 10616 -120
==========================================
- Hits 7421 7351 -70
+ Misses 2752 2711 -41
+ Partials 563 554 -9
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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
critno longer auto-promotes into range mode based on branch graph inspection. Stack review is now opt-in via--pr <num|url>or--range <baseSHA>..<headSHA>.--working-treeflag, which only existed as a bypass for the auto-promote.autodetect.go/autodetect_test.go(575 lines). Shared helpers (walkAncestors,topicChainSHAs, branch-tip lookups) remain inpicker.goand are untouched — the stack chip / popover UI still works when the user explicitly opts into range mode.This is a behavior reversal of the v2 pass on #391. Agent skills already document
--pr/--range, so no integration prompt changes are needed.Review
Test plan
go buildcleangofmt -l .cleango vet ./...cleango test ./...passesgolangci-lint run ./...0 issues🤖 Generated with Claude Code