Skip to content

ci: check out PR head instead of merge ref in e2e workflow - #940

Merged
AmethystLiang merged 1 commit into
mainfrom
fix-e2e-merge-ref
Apr 22, 2026
Merged

AmethystLiang merged 1 commit into
mainfrom
fix-e2e-merge-ref

Conversation

@AmethystLiang

Copy link
Copy Markdown
Contributor

Summary

  • The e2e reusable workflow (.github/workflows/e2e.yml) defaults ref to github.ref, which on pull_request events is refs/pull/N/merge.
  • GitHub does not compute that ref when the PR has conflicts or hasn't yet computed the merge commit, so actions/checkout fails with fatal: couldn't find remote ref refs/pull/N/merge — unrelated to the code under test.
  • Pass github.event.pull_request.head.sha from pr.yml so the e2e job checks out the PR head directly. No change to what is tested; only the checkout ref.

Motivating failure: #937, run https://github.com/stablyai/orca/actions/runs/24768962365/job/72470149899

Test plan

  • CI runs on this PR; e2e job checks out the PR head SHA and proceeds past the checkout step.

The e2e reusable workflow defaulted to github.ref, which on
pull_request events is refs/pull/N/merge. GitHub does not compute
that ref when the PR has conflicts or before the merge commit is
ready, causing actions/checkout to fail with "couldn't find remote
ref refs/pull/N/merge" for reasons unrelated to the code.

Pass github.event.pull_request.head.sha from pr.yml so e2e checks
out the PR head directly.

Motivating failure: https://github.com/stablyai/orca/actions/runs/24768962365
Seen on #937.
@AmethystLiang
AmethystLiang merged commit 00fdb8e into main Apr 22, 2026
2 checks passed
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
)

The e2e reusable workflow defaulted to github.ref, which on
pull_request events is refs/pull/N/merge. GitHub does not compute
that ref when the PR has conflicts or before the merge commit is
ready, causing actions/checkout to fail with "couldn't find remote
ref refs/pull/N/merge" for reasons unrelated to the code.

Pass github.event.pull_request.head.sha from pr.yml so e2e checks
out the PR head directly.

Motivating failure: https://github.com/stablyai/orca/actions/runs/24768962365
Seen on stablyai#937.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant