Skip to content

An unexpected error occurred: Request failed \"404 Not Found\"". #2738

@DannyBrown-xx

Description

@DannyBrown-xx

Do you want to request a feature or report a bug?
Bug

What is the current behavior?
I have a package which only depends on modules from the npmjs repository. They are predominantly public repositories, however 5 of them are private repositories scoped using an @ symbol. Again, these are hosted on npmjs.

Up until some time today all of them would download an install without issue. However, something has changed and now one of them fails to install with the following error:

error An unexpected error occurred: "http://registry.npmjs.org/@pepperhq/hmac-http-authentication/-/hmac-http-authentication-0.1.2.tgz: Request failed \"404 Not Found\"".

As I stated previously, the other private repositories (all within the same @ scope) download and install as intended. This leads me to think this isn't an authentication issue.

My .npmrc which is in the root of my project and contains my _authToken looks like this:

//registry.npmjs.org/:_authToken=TOKEN_HERE

I have already completed the following activities:

  1. Logging in using npm login again to get a fresh accessToken
  2. Ensuring the package name is correct (I copied it from the npm website just to be sure)
  3. Running rm -rf node_modules && rm yarn.lock && yarn cache clean
  4. Removing the offending package from my package.json and attempting to re yarn add it
  5. Attempting to run the equivalent npm install --save command. This worked.

If the current behavior is a bug, please provide the steps to reproduce.
As I am unsure of the cause I am unsure how to reproduce. Am willing to discuss further on Discord or in comments on this Issue.

What is the expected behavior?
I expect Yarn to install all of my private repositories from npmjs

Please mention your node.js, yarn and operating system version.
Taken from yarn-error.log

Yarn version: 
  0.20.3

Node version: 
  6.9.5

Platform: 
  darwin x64

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions