Skip to content

fix: SublibraryCI fetch depth causes merge base failure on fork PRs#3159

Merged
ChrisRackauckas merged 1 commit intoSciML:masterfrom
ChrisRackauckas-Claude:fix-sublibrary-ci-fetch-depth
Mar 17, 2026
Merged

fix: SublibraryCI fetch depth causes merge base failure on fork PRs#3159
ChrisRackauckas merged 1 commit intoSciML:masterfrom
ChrisRackauckas-Claude:fix-sublibrary-ci-fetch-depth

Conversation

@ChrisRackauckas-Claude
Copy link
Copy Markdown
Contributor

Summary

  • The detect-changes job in SublibraryCI.yml fails with fatal: origin/master...HEAD: no merge base on PRs from forks (e.g. fix: DynamicQuantities compatibility in core + differentiation paths #3126)
  • Root cause: git fetch origin master --depth=1 fetches only 1 commit of the base branch, which is insufficient for Git to compute the merge base needed by the three-dot diff (origin/master...HEAD)
  • Fix: remove --depth=1 so the full base branch history is fetched, consistent with the fetch-depth: 0 already configured on the checkout step

Test plan

🤖 Generated with Claude Code

The detect-changes job fails with "fatal: origin/master...HEAD: no merge
base" on fork PRs because `git fetch origin master --depth=1` only
retrieves a single commit of master history. This is insufficient for
Git to compute the merge base needed by the three-dot diff.

Remove the --depth=1 flag so the full base branch history is fetched,
matching the fetch-depth: 0 already set on checkout.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@ChrisRackauckas ChrisRackauckas merged commit ec9612e into SciML:master Mar 17, 2026
92 of 94 checks passed
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.

2 participants