hiqdev / asset-packagist

Asset Packagist
https://asset-packagist.org
BSD 3-Clause "New" or "Revised" License
247 stars 25 forks source link

Package update failed: npm-asset/bootstrap-datepicker #68

Closed schmunk42 closed 7 years ago

schmunk42 commented 7 years ago

I actually tried to install AdminLTE via npm

> composer require -vv --no-plugins npm-asset/admin-lte 
Using version dev-master for npm-asset/admin-lte
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Dependency resolution completed in 0.069 seconds
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Installation request for npm-asset/admin-lte dev-master -> satisfiable by npm-asset/admin-lte[dev-master].
    - npm-asset/admin-lte dev-master requires npm-asset/bootstrap-datepicker >=1.7.0,<2.0.0 -> no matching package found.

Potential causes:
 - A typo in the package name
 - The package is not available in a stable-enough version according to your minimum-stability setting
   see <https://getcomposer.org/doc/04-schema.md#minimum-stability> for more details.

Read <https://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.

Installation failed, reverting ./composer.json to its original content.

So I looked up the missing package on ap: https://asset-packagist.org/package/search?query=bootstrap-datepicker&platform=bower%2Cnpm

But ap shows (https://asset-packagist.org/package/npm-asset/bootstrap-datepicker)

npm-asset/bootstrap-datepicker see on Npm
Fetch updates from Npm
Package update failed
Could you ensure this package exists on npmjs.com?

Think asset-packagist is guilty? Report on GitHub

And the package exists on npm, see https://www.npmjs.com/package/bootstrap-datepicker - I thought you're "guilty" ;)

PS: I would be really interested in the underlying issue here, since I fear a lot of problems coming up when using more and more npm packages. (see also https://github.com/yiisoft/yii2/issues/14297)

SilverFire commented 7 years ago

It happens because one of bootstrap-datepicker releases contains invalid version constraint:

Failed to update package "npm-asset/bootstrap-datepicker": 
Could not parse version constraint >=1.1.0,,<2.0: Invalid version string "1.1.0,,<2.0"
SilverFire commented 7 years ago

Same here: https://github.com/hiqdev/asset-packagist/issues/25

SilverFire commented 7 years ago

Create a PR to FXP: https://github.com/fxpio/composer-asset-plugin/pull/308/files

SilverFire commented 7 years ago

PR merged, will deploy tomorrow

SilverFire commented 7 years ago

Deployed, package is available: https://asset-packagist.org/package/npm-asset/bootstrap-datepicker