Skip to content

Fix ADO npm caching and package releases - #1777

Merged
Branden Bonaby (bbonaby) merged 5 commits into
mainfrom
user/bbonaby/more-fixes-for-pipeline-and-release
Nov 14, 2026
Merged

Branden Bonaby (bbonaby) merged 5 commits into
mainfrom
user/bbonaby/more-fixes-for-pipeline-and-release

Conversation

@bbonaby

@bbonaby Branden Bonaby (bbonaby) commented Nov 14, 2026 •

Copy link
Copy Markdown
Collaborator

📖 Description

  • Remove shared npm caches that caused ADO post-job failures.
  • Allow npm SDK and NVX packages to be released together or separately.
  • Publish NVX first for npm/NuGet and run package selectors from build artifacts.

No API or schema changes; no design/API spec required.

🔗 References

#1774

🔍 Validation

Needs verification in the ADO build to confirm.

  • powershell.exe -NoProfile -File .\scripts\ci\test-npm-release-selection.ps1 — passed locally.
  • powershell.exe -NoProfile -File .\scripts\ci\test-nuget-release-selection.ps1 — passed locally.

✅ Checklist

  • Signed the Contributor License Agreement
  • Linked to an issue
  • For features or changes requiring a spec: linked the issue with maintainer-applied feature-accepted
  • For implementation: linked the required approved and merged design/API spec, or explained why no spec is required
  • Feature issue remains open unless this PR completes all agreed implementation, validation, and documentation
  • Updated documentation (if applicable)
  • Updated Copilot instructions (if build, architecture, or conventions changed)
  • If this PR changes Cargo.lock, the dependency-feed-check check passes (see pull request builds)

📋 Issue Type

  • Bug fix
  • Feature
  • Task
Microsoft Reviewers: Open in CodeFlow

Remove cross-run npm caches that restore multi-gigabyte SDK tarballs and fail during the post-job archive save. Stage and validate SDK and NVX npm packages independently for release.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e8d6ae37-9de9-456f-b542-60c846dd26f4
Ship npm and NuGet release selectors with their build artifacts. Both release pipelines must consume artifact inputs because 1ES rejects repository checkout in release jobs.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e8d6ae37-9de9-456f-b542-60c846dd26f4
Publish the selected NVX runtime before the SDK in npm and both NuGet release targets, so a failed runtime publication prevents SDK publication.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e8d6ae37-9de9-456f-b542-60c846dd26f4
Add brief purpose headers and readable sections without changing package validation. Cover the public and internal NuGet artifact layouts in the existing selection checks.

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

Copilot-Session: e8d6ae37-9de9-456f-b542-60c846dd26f4
@bbonaby
Branden Bonaby (bbonaby) requested a review from a team as a code owner November 14, 2026 04:23
Copilot AI balanced review requested due to automatic review settings November 14, 2026 04:23
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@bbonaby

Copy link
Copy Markdown
Collaborator Author

/azp run

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.

🔵 Needs a closer look

ADO/1ES validation is still pending for artifact-provided selector execution, release publishing order, and resolution of npm cache post-job failures, none of which local selector fixtures establish.

No open issues 🎉

What changed in this PR

Follows up on #1774 to address Azure DevOps npm cache failures and improve MXC package releases, without changing public APIs or schemas.

Changes:

  • Removes shared npm caches from packaging and SDK test jobs.
  • Adds independent npm SDK/NVX selection, publishes NVX first for npm and NuGet, and runs selectors from build artifacts.
  • Adds npm selection regression tests and extends NuGet coverage. Azure DevOps verification remains pending.
File Description
scripts/​ci/​test-nuget-release-selection.ps1 Tests artifact-local selection, public/internal versions, and NVX-first ordering.
scripts/​ci/​test-npm-release-selection.ps1 Adds package selection, staging, and rejection tests.
.github/​workflows/​Build.Windows.Job.yml Runs npm selection tests on Windows x64.
.azure-pipelines/​templates/​SDK.Unit.Test.Job.yml Removes shared npm caching from unit tests.
.azure-pipelines/​templates/​SDK.Integration.Test.Job.yml Removes shared npm caching from integration tests.
.azure-pipelines/​templates/​Package.NpmSdk.Job.yml Removes shared npm caching and bundles the release selector.
.azure-pipelines/​templates/​DotNet.Build.Job.yml Bundles the NuGet release selector.
.azure-pipelines/​scripts/​select-npm-packages.ps1 Validates and stages selected npm packages.
.azure-pipelines/​scripts/​select-dotnet-nuget-packages.ps1 Clarifies selection stages and simplifies error handling.
.azure-pipelines/​README.md Documents package selection and partial-release retries.
.azure-pipelines/​1ES.Release.Nuget.yml Uses the artifact-local selector and publishes NVX first.
.azure-pipelines/​1ES.Release.Npm.yml Adds independent package selection and NVX-first publishing.

Review effort: Balanced

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: e8d6ae37-9de9-456f-b542-60c846dd26f4

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.

🔵 Needs a closer look

An ADO/1ES run is still needed to verify cache-failure removal, artifact-bundled selector execution, and ESRP package publication, which local tests and offline review cannot cover.

No open issues 🎉

Review effort: Balanced

@bbonaby
Branden Bonaby (bbonaby) merged commit 6a89e69 into main Nov 14, 2026
32 checks passed
@bbonaby
Branden Bonaby (bbonaby) deleted the user/bbonaby/more-fixes-for-pipeline-and-release branch November 14, 2026 05:48
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