yarnpkg / yarn

The 1.x line is frozen - features and bugfixes now happen on https://github.com/yarnpkg/berry
https://classic.yarnpkg.com
Other
41.44k stars 2.73k forks source link

Regression in 0.16 re: outdated & upgrade with custom registry #1413

Open STRML opened 8 years ago

STRML commented 8 years ago

We have a local registry specified in our .yarnrc.

This particular error manifests with a fork we're temporarily using of ampersand-collection-lodash-mixin. We typically use very high version numbers for this. The returned package manifest contains the versions 0.50.0 and 0.51.0, as well as the base package's versions (1.0.1-4.0.0).

With 0.15.1, outdated worked fine:

$ yarn outdated
yarn outdated v0.15.1
Package                                 Current       Wanted        Latest
...
✨  Done in 11.92s.

But in 0.16.1, we have the following error:

$ npm i -g yarn
...
/usr/local/lib
└─┬ yarn@0.16.1
$ yarn outdated
yarn outdated v0.16.1
error Couldn't find any versions for ampersand-collection-lodash-mixin that matches ^51.0.0. Possible versions: 1.0.1, 1.0.2, 2.0.0, 2.0.1, 3.0.0, 4.0.0
info Visit https://yarnpkg.com/en/docs/cli/outdated for documentation about this command.

I read #1073 which seemed to have some success with yarn set config and/or some trailing slashes, but none of this worked for us.

Looking at our server logs, I am not seeing any actual hit for the package metadata. Clearing cache does not help.

arb commented 8 years ago

Was able to reproduce this locally with our private registry.

STRML commented 7 years ago

I can confirm the issue appears to be prioritizing root-level .npmrc over even local .yarnrc files. My root .npmrc is not configured to our private registry (I use a command alias for instead). Moving it over fixes the issue.

kraklin commented 7 years ago

I can also confirm the same problem. .yarnrc seem to be ignored, when I created .npmrc with same settings, yarn started to pull packages from our local repository. Looks like the support for .yarnrc has been dropped

arb commented 7 years ago

Is that documented anywhere?