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
safe_outputs: git fetch fails when bundle targets the currently checked-out branch #32069
The safe_outputs job fails with exit code 128 when the agent pushes commits to a branch and creates a PR from that same branch in the same run.
Error
fatal: refusing to fetch into branch 'refs/heads/autoloop/perf-comparison'
checked out at '/home/runner/work/tsessebe/tsessebe'
##[error]Failed to apply bundle: The process '/usr/bin/git' failed with exit code 128
##[error]✗ Message 2 (create_pull_request) failed: Failed to apply bundle
Git refuses because refs/heads/autoloop/perf-comparison is currently checked out
PR creation fails, remaining safe outputs are cancelled
Root cause
safe_output_handler_manager.cjs doesn't account for the case where the bundle's target branch is the one currently checked out. The git fetch <bundle> <ref>:<ref> command fails when <ref> matches HEAD.
Suggested fix
Before applying a bundle, either:
git checkout --detach (detach HEAD so no branch ref is "checked out")
git switch to a throwaway branch or main before fetching
Use git update-ref to update the branch ref without requiring it to not be checked out
Impact
The agent's code changes were pushed successfully, but the PR was never created. The workflow reports as failed even though all substantive work completed.
Activity
[community] Update community contributions in README