Skip to content

Smoke tests: install dependencies from public npm instead of the internal feed#2563

Open
TalZaccai wants to merge 1 commit into
mainfrom
talzacc/smoke-tests-public-npm
Open

Smoke tests: install dependencies from public npm instead of the internal feed#2563
TalZaccai wants to merge 1 commit into
mainfrom
talzacc/smoke-tests-public-npm

Conversation

@TalZaccai

Copy link
Copy Markdown
Contributor

Why

The ADO smoke-test pipeline added in the recent WIF migration (#2549, #2551)
restores dependencies from the org's internal Azure Artifacts feed, while the
GitHub Actions build lanes (build_ts, build_package_shell) and local dev use
the public npm registry. That difference opens a gap between the two build
environments: a PR can be green on the GitHub builds but red on smoke whenever a
freshly-published transitive version isn't yet present in the internal feed —
e.g. a Dependabot lockfile bump fails with ERR_PNPM_FETCH_404 (qs@6.15.3 in
#2556), even though every GitHub check passes.

This PR closes that gap on the smoke side by resolving packages from public npm —
the same source the rest of CI and local dev already use.

We intentionally fix this here rather than wiring internal-feed authentication
into GitHub Actions. The original intent of the last two WIF PRs was secretless
Azure auth (Key Vault / Azure OpenAI), not npm package sourcing — the
internal feed only came along incidentally via the shared
include-prepare-repo.yml template. Aligning smoke on public npm keeps package
resolution consistent across all CI without adding any new npm-registry auth work
on the GitHub side.

Changes

  • pipelines/include-prepare-repo.yml — make registry optional. The
    .npmrc + npmAuthenticate steps now run only when a registry is supplied.
    This is backward-compatible: the build/publish pipelines still pass
    $(REGISTRY) and are unaffected.
  • pipelines/azure-smoke-tests.yml — omit registry, so the smoke job
    installs from public npm, matching the GitHub Actions lanes.

Not changed

  • The ADO build/publish pipelines continue to use the internal feed.
  • The smoke pipeline's WIF / Azure auth is untouched — still used for the Azure
    OpenAI secrets, which is independent of the npm registry.

The ADO smoke pipeline restored dependencies from the org's internal Azure
Artifacts feed, while the GitHub Actions build lanes and local dev use public
npm. That split caused smoke tests to fail (ERR_PNPM_FETCH_404) whenever a
Dependabot lockfile bump introduced a freshly-published transitive version not
yet present in the internal feed, even though the GitHub builds passed.

Make 'registry' optional in include-prepare-repo.yml: when omitted, the .npmrc
and npmAuthenticate steps are skipped and pnpm uses the default public npm
registry. The smoke pipeline now omits 'registry' so it installs from public
npm, consistent with the other CI lanes. The smoke tests only need the WIF
service connection for Azure OpenAI secrets, which is independent of the npm
registry. The 4 build/publish pipelines still pass $(REGISTRY) and are
unaffected.

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

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.

Pull request overview

Aligns the Azure DevOps smoke-test pipeline’s dependency restore behavior with GitHub Actions and local development by using the public npm registry by default, avoiding failures caused by lag in internal Azure Artifacts feed mirroring.

Changes:

  • Makes registry optional in include-prepare-repo.yml, and only writes/authenticates .npmrc when a custom registry is provided.
  • Updates azure-smoke-tests.yml to omit the registry parameter so smoke installs resolve from the default public npm registry.
Show a summary per file
File Description
pipelines/include-prepare-repo.yml Adds optional registry parameter default and guards .npmrc + npmAuthenticate behind a non-empty registry check.
pipelines/azure-smoke-tests.yml Stops passing registry and updates comments to reflect public npm restore behavior for smoke tests.

Review details

Tip

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

  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Low

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