Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lodash-amd installs 3.5.3 for ~3.5.0, but npm doesn't see this version #260

Closed
nazar-pc opened this issue Oct 22, 2016 · 6 comments
Closed
Assignees
Labels
Milestone

Comments

@nazar-pc
Copy link

It looks like version installed by fxp/composer-asset-plugin is just copied from GitHub (the same contents as here), however, NPM only knows following versions (no 3.5.3):

npm ERR! notarget No compatible version found: lodash-amd@3.5.3
npm ERR! notarget Valid install targets:
npm ERR! notarget 4.16.4, 4.16.3, 4.16.2, 4.16.1, 4.16.0, 4.15.0, 4.14.2, 4.14.1, 4.14.0, 4.13.1, 4.13.0, 4.12.0, 4.11.2, 4.11.1, 4.11.0, 4.10.0, 4.9.0, 4.8.2, 4.8.0, 4.7.0, 4.6.1, 4.6.0, 4.5.1, 4.5.0, 4.4.0, 4.3.0, 4.2.1, 4.2.0, 4.1.0, 4.0.1, 4.0.0, 3.10.2, 3.10.1, 3.10.0, 3.9.3, 3.9.2, 3.9.0, 3.8.0, 3.7.0, 3.6.0, 3.5.0, 3.4.0, 3.3.1, 3.3.0, 3.2.0, 3.1.0, 3.0.1, 3.0.0, 2.4.1, 2.4.0, 2.3.0, 2.2.1, 2.2.0, 2.1.0, 2.0.0

Moreover, installing 3.5.0 using NPM results in very different contents of the lodash-amd directory:

$ cat package.json              
{
  "_args": [
    [
      {
        "raw": "lodash-amd@3.5",
        "scope": null,
        "escapedName": "lodash-amd",
        "name": "lodash-amd",
        "rawSpec": "3.5",
        "spec": ">=3.5.0 <3.6.0",
        "type": "range"
      },
      "/media/Data/tmp"
    ]
  ],
  "_from": "lodash-amd@>=3.5.0 <3.6.0",
  "_id": "lodash-amd@3.5.0",
...
$ ls                            
compat/  LICENSE.txt  main.js  modern/  package.json  README.md
@nazar-pc
Copy link
Author

lodash-amd in my scenario is a dependency of npm-asset/scribe-plugin-sanitizer ^0.1 which I'm trying to install.
However, when I require it explicitly:

... requires npm-asset/lodash-amd 3.5.3 -> no matching package found

@nazar-pc
Copy link
Author

When added npm-asset/lodash-amd 3.5.0 dependency in addition to npm-asset/scribe-plugin-sanitizer ^0.1 it finally installed correct version.

@francoispluchino
Copy link
Member

$ composer require npm-asset/lodash-amd:3.5.0

This command works. On the other hand, the v3.5.3 is not registered in NPM, and the Github tags are formatted with -npm-packages, it's for this reason that you cannot install this version.

@nazar-pc
Copy link
Author

Yes, it works when you install package directly. But try to install npm-asset/scribe-plugin-sanitizer:^0.1.

@nazar-pc
Copy link
Author

Another example - for npm-asset/scribe-plugin-inline-styles-to-elements ^0.1 I'm getting source from 0.1.1 tag (which is the same as bower install scribe-plugin-inline-styles-to-elements#^0.1), but NPM only has 0.1.0 version with completely different source.

In this case it feels like this plugin sometimes installs Bower packages (or suitable Git tags) even when NPM package is required.

@francoispluchino francoispluchino self-assigned this Feb 15, 2017
@francoispluchino francoispluchino added this to the 1.3.0 milestone Feb 15, 2017
@francoispluchino
Copy link
Member

Fixed by 1600e62.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants