Closed re3lex closed 8 years ago
Check your error message:
Could not load package rmrevin/yii2-fontawesome in http://packagist.org: [UnexpectedValueException] Could not parse version constraint v4.1.*:
Invalid version string "v4.1.*"
Looks like you have that in your composer.json
Or check it with depends
$ composer depends rmrevin/yii2-fontawesome
dmstr/yii2-adminlte-asset requires rmrevin/yii2-fontawesome (~2.9)
It's not a problem of adminlte-asset
composer require dmstr/yii2-adminlte-asset "2.*"
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
- Installing yiisoft/yii2-composer (2.0.3)
Loading from cache
- Installing bower-asset/jquery (2.1.4)
Loading from cache
- Installing bower-asset/yii2-pjax (v2.0.5)
Loading from cache
- Installing bower-asset/punycode (v1.3.2)
Loading from cache
- Installing bower-asset/jquery.inputmask (3.1.63)
Loading from cache
- Installing cebe/markdown (1.1.0)
Loading from cache
- Installing ezyang/htmlpurifier (v4.6.0)
Loading from cache
- Installing yiisoft/yii2 (2.0.6)
Loading from cache
- Installing bower-asset/fontawesome (v4.5.0)
Loading from cache
- Installing rmrevin/yii2-fontawesome (2.13.0)
Loading from cache
- Installing almasaeed2010/adminlte (v2.3.2)
Loading from cache
- Installing cebe/yii2-gravatar (1.1)
Loading from cache
- Installing bower-asset/bootstrap (v3.3.5)
Loading from cache
- Installing yiisoft/yii2-bootstrap (2.0.5)
Loading from cache
- Installing dmstr/yii2-adminlte-asset (2.2.4)
Loading from cache
Writing lock file
Generating autoload files
Also make sure to have:
fxp/composer-asset-plugin v1.1.1
hi schmunk42 thanks for your input I will check my local
looks like some issue in composer's cache This helped
composer self-update
Hi @schmunk42 composer require dmstr/yii2-adminlte-asset "2.*" ./composer.json has been created is not working in my case.
$ composer depends rmrevin/yii2-fontawesome yiister/yii2-gentelella requires rmrevin/yii2-fontawesome (~2.0)
$ composer require yiister/yii2-gentelella Using version ^1.3 for yiister/yii2-gentelella ./composer.json has been updated Loading composer repositories with package information Updating dependencies (including require-dev)
[RuntimeException]
Could not load package rmrevin/yii2-fontawesome in http://packagist.org: [UnexpectedValueException] Could not parse version constraint v4.1.
: Invalid version string "v4.1."
[UnexpectedValueException]
Could not parse version constraint v4.1.: Invalid version string "v4.1."
@apps25
[RuntimeException]
Could not load package rmrevin/yii2-fontawesome in http://packagist.org: [UnexpectedValueException] Could not parse version constraint v4.1.
: Invalid version string "v4.1."
Please double-check where the invalid version string for yii2-fontawesome
is coming from. We're requiring ~2.9
https://github.com/dmstr/yii2-adminlte-asset/blob/master/composer.json#L22 - does not look like an issue with this repo.
Hi @schmunk42 Thanks for reply, I want to clear that this problem is at Live project I was going through a blog and trying to resolve the error but now i am facing this issue. my installed composer is : Composer version 1.0-dev (9f6fdfd703f433bd0777fd89fb4684908a6c4f06) 2015-09-07 and after running diagnose command i am getting:
Checking composer.json: FAIL require.yiisoft/yii2 : unbound version constraints (>=2.0.6) should be avoided require.yiisoft/yii2-bootstrap : unbound version constraints () should be avoided require.yiisoft/yii2-swiftmailer : unbound version constraints () should be avoided require.yiisoft/yii2-imagine : unbound version constraints () should be avoided require.bupy7/yii2-activerecord-history : unbound version constraints () should be avoided require.linslin/yii2-curl : unbound version constraints () should be avoided require.yii2mod/yii2-bx-slider : unbound version constraints () should be avoided require.FortAwesome/Font-Awesome : unbound version constraints () should be avoided require.jenn0pal/yii2-aws-sdk : unbound version constraints () should be avoided Checking platform settings: OK Checking git settings: OK Checking http connectivity to packagist: OK Checking https connectivity to packagist: OK Checking github.com rate limit: OK Checking disk free space: OK Checking composer version: FAIL You are not running the latest version
====================================================== and after running composer validate:
composer update --lock Loading composer repositories with package information Updating dependencies (including require-dev)
[RuntimeException]
Could not load package rmrevin/yii2-fontawesome in http://packagist.org: [UnexpectedValueException] Could not parse version constraint v4.1.
: Invalid version string "v4.1."
[UnexpectedValueException]
Could not parse version constraint v4.1.: Invalid version string "v4.1."
@apps25 Please format your output, see https://help.github.com/articles/basic-writing-and-formatting-syntax/ - important parts are not shown correctly like *
Secondly, update your composer binary, your version is over 2 years old Composer version 1.0-dev (9f6fdfd703f433bd0777fd89fb4684908a6c4f06) 2015-09-07
- and clear your caches, like mentioned in https://github.com/dmstr/yii2-adminlte-asset/issues/76#issuecomment-164175420
Thirdly, never ever use update
in production, commit a .lock
file and run install
.
Last but not least, I still don't see why this should be an issue of yii2-adminlte-asset
.
@schmunk42
I got it thanks :+1:
Hi,
I'm trying to install version 2 through composer but getting this error
How to get yii2-adminlte-asset installed?