Skip to content

Disable AddCommitsToPR on VS insertion to avoid spurious build failures#857

Open
marcpopMSFT wants to merge 1 commit into
engfrom
marcpopMSFT-disable-addcommitstopr
Open

Disable AddCommitsToPR on VS insertion to avoid spurious build failures#857
marcpopMSFT wants to merge 1 commit into
engfrom
marcpopMSFT-disable-addcommitstopr

Conversation

@marcpopMSFT

Copy link
Copy Markdown
Member

What

Set AddCommitsToPR: false for the MicroBuild Insert VS Payload task in eng/pipelines/templates/steps/workload-insertion-steps.yml.

Why

In build 3009141 the VS insertion succeeded — the PR (DevDiv #753336) was created — but the task then failed with exit code 1 on the post-PR "Copy Commit Details to PR" step:

##[error]No changes found between 20260626.3 and 20260626.2 ...

Root cause

The AddCommitsToPR feature tries to compute the list of commits to paste into the PR description after the PR already exists, and treats failure as fatal. Two environmental factors triggered it:

  1. No ADO bearer token is available to call the metadata service — so it fell back to legacy "previous build" logic.
  2. The legacy fallback selected a canceled, same-commit sibling build (20260626.3, build 3009185, same source commit 7ed63c0f) as the diff baseline → empty diff → fatal No changes found.

So a cosmetic, post-PR description step is failing builds even though the insertion itself worked.

Why disabling is acceptable

The commits rolled into these insertions are version-number updates, not meaningful code changes, so the auto-generated commit list adds little value and isn't worth failing the build over. The information is still discoverable from the component-version diff and this repo's history.

Impact

  • ✅ Insertion PR, reviewers, build policies, and auto-complete are unchanged.
  • ➖ The VS PR description will no longer include the auto-populated source-commit list.

Follow-ups (not in this PR)

  • File a MicroBuild bug: "Copy Commit Details to PR" should not fatally fail the task after the PR is created, and the metadata-service bearer-token issue should be addressed.
  • Reduce concurrent/duplicate same-commit runs of the official-ci pipeline to avoid poisoning the diff baseline.

The MicroBuild Insert VS Payload task's 'Copy Commit Details to PR' feature (AddCommitsToPR) fatally fails the task *after* the insertion PR has already been created when it cannot compute a commit diff. This happened in build 3009141: the PR (DevDiv #753336) was created successfully, then the task errored with 'No changes found between 20260626.3 and 20260626.2' and exited 1.

Triggers: the metadata service had no ADO bearer token, so it fell back to legacy logic and selected a canceled same-commit sibling build (20260626.3) as the diff baseline, yielding an empty diff that the plugin treats as fatal.

The commits rolled into these insertions are version-number updates rather than real code changes, so the auto-generated commit list provides little value and isn't worth failing the build over. The insertion PR, reviewers, build policies and auto-complete are unaffected.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 26, 2026 22:10

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

Disables MicroBuild’s AddCommitsToPR behavior for the “Insert VS Payload” step to prevent otherwise-successful insertion runs from failing due to a non-essential post-PR “Copy Commit Details to PR” step.

Changes:

  • Set AddCommitsToPR: false for the VS insertion task.
  • Added in-file rationale documenting the known failure mode and why the feature is not worth failing the build over for workload-version insertions.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@marcpopMSFT marcpopMSFT requested a review from lbussell June 26, 2026 22:17
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