You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ci: pr-status misses a moved base's change to a file the pull request renames #4152
bun scripts/pr-status.ts <pr> --expect-base <sha> reports in baseGained.overlapsThisPr which of the files a moved base gained the pull request also changes. It matches the base's files against the paths the pull request changes (changedFiles in scripts/pr-status.ts, as of PR #4151; before it, the files field of gh pr view).
Both sources name a file the pull request renames by its new path only. Observed with gh 2.103.3 on merged PR #3483, which renamed experiments/turn-surface-capture.parked.ts to experiments/turn-surface-capture.test.ts:
gh pr view 3483 --json files lists experiments/turn-surface-capture.test.ts and not the old path.
gh api repos/<owner>/<repo>/pulls/3483/files lists the entry with status: "renamed", filename the new path and previous_filename the old one.
A base that moved by changing the old path lists that old path in its comparison. It matches nothing in the pull request's list, so overlapsThisPr does not name it, although the pull request renames the very file the base changed. That is one of the overlaps most likely to need a rebase.
This is independent of the size of the pull request, and it is not the truncation #4114 fixed.
Scope
Count a renamed file's previous path as changed by the pull request when computing baseGained.overlapsThisPr.
Out of scope
The other direction, a base that renames a file the pull request edits: the comparison's own entries would need the same treatment and a decision on which path to print. File separately if wanted.
Any other field pr-status prints.
scripts/integrate.ts and scripts/review-receipt.ts: they read the Git diff.
Acceptance criteria
When the base gained a change to a path that the pull request renames away from, pr-status --expect-base names that path in baseGained.overlapsThisPr. A test in scripts/skill-tests/pr-status.test.ts fails before the change.
A pull request with no renamed file prints the same output as before.
Activity
chore(ci): drop the diagram materializer's dead checkout check, count…