6
votes

I'm trying to configure Azure Artifacts to serve as a single source for all private and public packages using npmjs.org as the upstream source. Some of the public npm packages are returning 404 Not Found from Azure Artifacts, loading from npmjs directly works fine though.

Example of npm install failing for a public package

C:\git-repos\alinta\FrontEnd.Sitecore>npm i react-app-polyfill
npm ERR! code E404
npm ERR! 404 Not Found - GET https://pkgs.dev.azure.com/AlintaDigital/_packaging/AlintaDigital/npm/registry/react-app-polyfill - NotFound
npm ERR! 404
npm ERR! 404  'react-app-polyfill@^1.0.1' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\jawan\AppData\Roaming\npm-cache\_logs\2020-03-22T23_17_20_270Z-debug.log

Some other public npm packages constantly failing to install are

  • react
  • isomorphic-fetch
  • cleave.js
  • history
  • object-assign

While some other public packages are available for use in Azure Artifacts available npm packages

Upstream sources setting has been configured as below Upstream sources

2

2 Answers

6
votes

Looks like this is a permissions issue. Can you please check to make sure that you (and other developers trying to pull from upstream sources) have Collaborator (or better) permissions?

Source: https://docs.microsoft.com/en-us/azure/devops/artifacts/feeds/feed-permissions?view=azure-devops

Az DevOps Feed permissions

3
votes

In my case I had to allow project scoped builds. Our Project Collection Build Service was already set as a contributor. But in the navigation menu under permissions there was an ellipses and when clicking it it gave me the option to select Allow project-scoped builds.