Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure Artifacts is returning 404 for some of the public npm packages

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

like image 587
Raj Avatar asked Mar 22 '20 23:03

Raj


2 Answers

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

like image 53
dansimpson Avatar answered Oct 05 '22 00:10

dansimpson


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.

like image 26
DigiBanks99 Avatar answered Oct 05 '22 01:10

DigiBanks99