Problem
The bundle transport for push_to_pull_request_branch (#30287) fails in the safe_outputs job because the job uses a shallow checkout (fetch-depth: 1). When git merge --ff-only tries to merge the bundle ref into the local branch, git refuses because the shallow clone doesn't have enough history to find a common ancestor.
[command]/usr/bin/git merge --ff-only refs/bundles/push-autoloop-build-tsb-pandas-typescript-migration
fatal: refusing to merge unrelated histories
##[error]Failed to apply bundle: The process '/usr/bin/git' failed with exit code 128
Reproduction
Every autoloop run on githubnext/tsessebe hits this. The safe_outputs job:
- Shallow-clones main (
fetch-depth: 1)
- Fetches the PR branch (
git fetch origin autoloop/build-tsb-pandas-typescript-migration)
- Fetches the bundle to
refs/bundles/...
- Tries
git merge --ff-only refs/bundles/... → fails: unrelated histories
The bundle contains commits that descend from the PR branch, but the shallow clone doesn't have enough history to see that relationship.
Possible fixes
- Unshallow before merge:
git fetch --unshallow (or deepen enough to find the merge base)
- Use
git update-ref instead of git merge --ff-only — directly point the branch at the bundle's HEAD (if the bundle is a strict superset)
- Use the GitHub API to update the branch ref instead of local git operations
- Increase fetch-depth in the safe_outputs checkout step
Impact
All autoloop programs on githubnext/tsessebe are blocked. Every run since the v0.72.1 upgrade fails at safe_outputs with this error.
Related
Problem
The bundle transport for
push_to_pull_request_branch(#30287) fails in thesafe_outputsjob because the job uses a shallow checkout (fetch-depth: 1). Whengit merge --ff-onlytries to merge the bundle ref into the local branch, git refuses because the shallow clone doesn't have enough history to find a common ancestor.Reproduction
Every autoloop run on githubnext/tsessebe hits this. The safe_outputs job:
fetch-depth: 1)git fetch origin autoloop/build-tsb-pandas-typescript-migration)refs/bundles/...git merge --ff-only refs/bundles/...→ fails: unrelated historiesThe bundle contains commits that descend from the PR branch, but the shallow clone doesn't have enough history to see that relationship.
Possible fixes
git fetch --unshallow(or deepen enough to find the merge base)git update-refinstead ofgit merge --ff-only— directly point the branch at the bundle's HEAD (if the bundle is a strict superset)Impact
All autoloop programs on githubnext/tsessebe are blocked. Every run since the v0.72.1 upgrade fails at safe_outputs with this error.
Related