Skip to content

Fix shallow merge-base handling for component fixtures - #333604

Open
Henning Dieterichs (hediet) wants to merge 1 commit into
mainfrom
hediet/fix-component-fixtures-merge-base
Open

Fix shallow merge-base handling for component fixtures#333604
Henning Dieterichs (hediet) wants to merge 1 commit into
mainfrom
hediet/fix-component-fixtures-merge-base

Conversation

@hediet

Copy link
Copy Markdown
Member

Summary

Increase the component fixture workflow's shallow history depth from 50 to 150 so merge-base lookup tolerates more target-branch activity.

If the merge base is still unavailable, emit an explicit warning and skip only the base-dependent screenshot comparison. Fixture rendering and blocks-ci validation continue to run.

This addresses the silent merge-base failure observed in https://github.com/microsoft/vscode/actions/runs/33221071634/job/99577739911?pr=333236.

Increase the history depth to 150 and skip screenshot comparison with an explicit warning if the merge base is still unavailable.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 7defd909-5470-4f45-97dc-09706d9c6570
Copilot AI balanced review requested due to automatic review settings August 31, 2026 17:52

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

Review tier: Balanced
Findings: 1 Medium severity

New issues introduced by this change (1)
Severity Finding
Medium severity .github/​workflows/​component-fixtures.yml — When this branch exits without base_sha, the diff is skipped, but the later PR-comment step still…
What changed in this PR

Improves component-fixture CI resilience when shallow history lacks a merge base.

Changes:

  • Increases fetch depth from 50 to 150.
  • Warns and skips base-dependent screenshot comparison when necessary.
  • Guards base-manifest and diff steps.
File Description
.github/​workflows/​component-fixtures.yml Updates shallow-history and screenshot comparison handling.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +188 to +190
if ! BASE_SHA=$(git merge-base "$EVENT_SHA" "$TARGET_REF"); then
echo "::warning::Unable to find a merge base between $EVENT_SHA and $TARGET_REF. The depth-150 shallow history may not contain their common ancestor; skipping screenshot comparison."
exit 0
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.

3 participants