Skip to content

Authenticate npm feed for Marketplace publishing - #9784

Merged
dibarbet merged 2 commits into
mainfrom
dibarbet-marketplace-publish-failure
Sep 21, 2026
Merged

dibarbet merged 2 commits into
mainfrom
dibarbet-marketplace-publish-failure

Conversation

@dibarbet

@dibarbet dibarbet commented Sep 17, 2026

Copy link
Copy Markdown
Member

Summary

  • Create a temporary npm configuration for the dotnet-public-npm feed in the release deployment job, which does not check out the repository.
  • Run npmAuthenticate@0 and pass the authenticated file to the Marketplace step through NPM_CONFIG_USERCONFIG.

Why

The public feed permits anonymous downloads of saved packages, but fetching versions that have not yet been saved from upstream requires authentication. The publishing script intentionally bootstraps the latest VSCE through an unpinned npx invocation, so a newly selected VSCE version or transitive dependency can fail with npm E401 before Marketplace publishing starts.

The existing Marketplace Azure service connection does not configure npm feed authentication. This change uses the job's Azure DevOps credentials for npm and leaves Marketplace authentication and the unpinned VSCE behavior unchanged.

Operational notes

  • The pipeline build identity needs Feed and Upstream Reader (Collaborator) permission on dotnet-public-npm to save uncached upstream packages.
  • The authentication change also applies when publishing existing artifacts.

dibarbet and others added 2 commits September 17, 2026 13:34
Configure and authenticate a temporary npmrc for the release deployment job, and pin its VSCE publishing tool to 4.0.0.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 58fecf1a-ae66-4349-bddd-aa0282d9612e
Retain the latest VSCE behavior now that the release job authenticates npm downloads from upstream.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 58fecf1a-ae66-4349-bddd-aa0282d9612e
@dibarbet
dibarbet marked this pull request as ready for review September 21, 2026 23:03
@dibarbet
dibarbet requested a review from a team as a code owner September 21, 2026 23:03
Copilot AI lite review requested due to automatic review settings September 21, 2026 23:03

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

🟢 Approval recommended

No blocking issues were identified.

Review effort: Lite
Findings: None

What changed in this PR

Authenticates the npm feed during Marketplace publishing so uncached VSCE packages can be downloaded.

Changes:

  • Creates and authenticates a temporary .npmrc.
  • Passes it via NPM_CONFIG_USERCONFIG.
File Description
azure-pipelines/​release.yml Configures npm feed authentication for Marketplace publishing.

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

@dibarbet
dibarbet merged commit 4d8e59b into main Sep 21, 2026
3 checks passed
@dibarbet
dibarbet deleted the dibarbet-marketplace-publish-failure branch September 21, 2026 23:25
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