Repository navigation
Worker: stack on an open series part or the PR that adds a named file - #416
Merged
Merged
Conversation
…; never restore from another branch A ticket titled as part 2 of a series named a file only part 1's open pull request adds. Dependency detection read only lines that say "depends on", so the run started from the default branch, then copied part 1's files in with restore_file from part 1's branch. The guard before the pull request caught the copied commits and the run failed. - A title like [Name 2/4] stacks on the latest earlier part of the same series that still has an open pull request. - A file the ticket names that the base lacks, added by exactly one open pull request, stacks on that pull request. - restore_file restores only from the pull request's base or a commit SHA; another branch is refused with the reason.
This was referenced Nov 3, 2026
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
A ticket titled as part 2 of a series named a file that only part 1's open pull request adds. Dependency detection only read lines saying "depends on" and the like, so the run started its branch from the default branch. The coder then copied part 1's files in with
restore_filefrom part 1's branch. The check before opening the pull request found the re-created commits, rebasing onto part 1 didn't apply cleanly, and the run failed.Changes
stack.rs: dependency detection, deterministic and in code, in this order:[Name n/m]stacks on the latest earlier part (same name and total) that still has an open pull request;restore_file(implement and feedback passes) restores only from the pull request's base or a commit SHA. Another branch is refused, with the reason and what to do instead, and the tool descriptions say so.Verification
restore_filesources; a correctly stacked branch copies nothing while copied commits still match.cargo fmt --check,cargo clippy -p worker --all-targets -D warnings, andcargo test -p worker: 1,159 passed, 0 failed.