I am having a problem with composer when I run composer update.
The relevant bits of my composer.json file looks like this:
"require": {
"php": ">=5.5.9",
"laravel/framework": "5.1.*",
"omnipay/common": "~2.0",
"omnipay/authorizenet": "~2.0",
"omnipay/firstdata": "~2.0",
"omnipay/stripe": "~2.0",
"omnipay/paypal": "~2.0"
},
"minimum-stability": "dev",
When I run composer update, I receive the following error:
[Composer\DependencyResolver\SolverProblemsException]
Problem 1
- The requested package omnipay/common could not be found in any version, there may be a typo in the package name.
Problem 2
- Installation request for omnipay/authorizenet ~2.0 -> satisfiable by omnipay/authorizenet[2.5.0].
- omnipay/authorizenet 2.5.0 requires omnipay/common ~2.2 -> no matching package found.
Problem 3
- Installation request for omnipay/firstdata ~2.0 -> satisfiable by omnipay/firstdata[v2.3.0].
- omnipay/firstdata v2.3.0 requires omnipay/common ~2.0 -> no matching package found.
Problem 4
- Installation request for omnipay/stripe ~2.0 -> satisfiable by omnipay/stripe[v2.4.3].
- omnipay/stripe v2.4.3 requires omnipay/common ~2.0 -> no matching package found.
Problem 5
- Installation request for omnipay/paypal ~2.0 -> satisfiable by omnipay/paypal[v2.6.3].
- omnipay/paypal v2.6.3 requires omnipay/common ~2.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.
I'm at a loss as to what direction to take to fix this or why it occurred in the first place. I last ran composer update several months ago and it ran with no issue.
There's no need to specifically require omnipay/common or omnipay/omnipay (which is a dummy package anyway).
(1) remove all of the omnipay/* lines from your composer.json
(2) The composer commands you need to bring your composer.json into having the correct versions are:
composer require omnipay/authorizenet
composer require omnipay/firstdata
composer require omnipay/stripe
composer require omnipay/paypal
Try running this command, I think composer will update your dependencies.
composer require omnipay/omnipay
I suppose the problem is with the package name. You can add omnipay/omnipay in your composer.json file as the package name.
I hope You Read All The Error Once. Its All Package You Declare is not found or not getting or its required update So, Just Remove the All The omipay packge form the Coposer.json and also Remove from ServiceProvider in config/app.php
Example Remove This Code Form Composer.json
"omnipay/common": "~2.0",
"omnipay/authorizenet": "~2.0",
"omnipay/firstdata": "~2.0",
"omnipay/stripe": "~2.0",
"omnipay/paypal": "~2.0"
And Then Try To Update Your Composer and Then After Install New Version Package From Here
I Hope Its Work For Your !!
Or
Follow This :
And Install The Package Again From :
https://packagist.org/packages/omnipay/paypal
And
https://github.com/thephpleague/omnipay-paypal
Related
when i run
composer require --dev phpunit/phpunit
i get the following message:
composer require --dev phpunit/phpunit
Using version ^6.2 for phpunit/phpunit
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for sebastian/object-enumerator (locked at 2.0.1) -> satisfiable by sebastian/object-enumerator[2.0.1].
- phpunit/phpunit 6.2.0 requires sebastian/object-enumerator ^3.0.2 -> satisfiable by sebastian/object-enumerator[3.0.2].
- phpunit/phpunit 6.2.1 requires sebastian/object-enumerator ^3.0.2 -> satisfiable by sebastian/object-enumerator[3.0.2].
- phpunit/phpunit 6.2.2 requires sebastian/object-enumerator ^3.0.2 -> satisfiable by sebastian/object-enumerator[3.0.2].
- phpunit/phpunit 6.2.3 requires sebastian/object-enumerator ^3.0.2 -> satisfiable by sebastian/object-enumerator[3.0.2].
- Conclusion: don't install sebastian/object-enumerator 3.0.2
- Installation request for phpunit/phpunit ^6.2 -> satisfiable by phpunit/phpunit[6.2.0, 6.2.1, 6.2.2, 6.2.3].
Installation failed, reverting ./composer.json to its original content.
Here is my composer json file:
"require": {
"php": "^7.0",
"laravel/framework": "^5.4",
"guzzlehttp/guzzle": "^6.3",
"symfony/psr-http-message-bridge": "^1.0",
"mcamara/laravel-localization": "^1.2",
"laravelcollective/html": "^5.4",
"laravel/socialite": "^3.0",
"yajra/laravel-datatables-oracle": "^7.9"
},
"require-dev": {
"fzaninotto/faker": "^1.6",
"symfony/css-selector": "^3.3",
"symfony/dom-crawler": "^3.3"
}
I tried to get from version 5.4 above and always get a similar error but with other dependecies, the only version that seems to work is 5.0
Run
$ composer require --dev phpunit/phpunit --update-with-dependencies
See https://getcomposer.org/doc/03-cli.md#require:
--update-with-dependencies: Also update dependencies of the newly required packages.
Note Deleting composer.lock in circumstances like this isn't really the best idea, as it might pull in dependencies that break your code in other places. You really only want to update a specific dependency at a time, rather than update all of them at once.
If you run a composer update with the composer.lock file and the vendor folder present, Composer will take the installed versions into accounts before updating.
Make sure you have the lock file committed into your project repository, to be able to restore the current version. Then try another update, but before that delete the lock file and vendor folder.
My experience is that such an update will not be affected by already installed versions which may prevent the necessary updates.
Another option for debugging the dependencies is to use composer why-not phpunit/phpunit 6.2.0 (use an explicit version you know exists - without version the output of the command is not meaningful). Composer will give you a list of dependencies that prevent the update, for you to investigate further.
I have a composer file with a dev-dependency that requires PHP >= 5.4.0. When I update on production (a 5.3 install (yes - I know!)) and explicitly pass the --no-dev option, composer still checks for the PHP version requirements from the dev packages.
Composer file:
{
"config": {
"vendor-dir": "./vendor/"
},
"require": {
"symfony/config" : "dev-master",
"twig/twig": "1.15.1",
"leafo/lessphp": "v0.4.0",
"simplepie/simplepie": "dev-master",
"contao/idna": "dev-master",
"swiftmailer/swiftmailer": "5.3.*#dev",
"james-heinrich/getid3": "dev-master",
"pda/pheanstalk": "v2.1.0",
"monolog/monolog": "1.9.1",
"pimple/pimple": ">1.0.0",
"doctrine/orm": "2.4.*",
"ircmaxell/password-compat": "1.0.3",
"raven/raven": "dev-curl-async",
"elasticsearch/elasticsearch": "~1.0",
"guzzle/guzzle": "3.9.2"
},
"require-dev": {
"codeception/codeception": "2.1.*#dev"
}
}
Codeception has a requirement for PHP 5.4.0+ and when I run composer update --no-dev I get the following:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for codeception/codeception 2.1.*#dev -> satisfiable by codeception/codeception[2.1.x-dev].
- codeception/codeception 2.1.x-dev requires php >=5.4.0 -> no matching package found.
Should composer be skipping the requirements checks for packages I've explicitly told it not to install? I have tried passing --ignore-platform-reqs but without success.
UPDATE
It appears that running it on PHP 5.3.10 completely ignores the --no-dev option and reports that it is installaling them:
composer update --no-dev
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for codeception/codeception 2.1.*#dev -> satisfiable by codeception/codeception[2.1.x-dev].
- codeception/codeception 2.1.x-dev requires php >=5.4.0 -> no matching package found.
You need to use --no-dev to not install the dev packages.
Solved!!!
It appears my composer file was a bash script that wasn't passing the parameters to the composer.phar file correctly.
This problem was of my own creation.
I have a Composer package that requires OtherPackage vs 1.0.*. I know that version 1.0.3 exists, but it keeps downloading version 1.0.1. I can't figure out why it is not getting the latest version.
my composer.json file:
"require": {
"MyVendor/OtherPackage": "1.0.*",
}
I figured this out because I tried to force version 1.0.3 and got the following error:
Your requirements could not be resolved to an installable set of packages.
- Installation request for myVendor/OtherPackage 1.0.3 -> satisfiable by MyVendor/OtherPackage[1.0.3]
- MyVendor/OtherPackage 1.0.3 requires OtherVendor/ThirdPackage 1.0.1 -> no matching package found.
So that's when I remembered that MyVendor/OtherPackage 1.0.1 didn't have the ThirdPackage dependency, while 1.0.2 and 1.0.3 did. I didn't include ThirdPackage in my composer.json requirements. As a result Composer was smart enough to get the latest version of OtherPackage that was satisfiable for all of my current dependencies.
My solution was just to add OtherVendor/ThirdPackage 1.0.1 to my requires declaration in composer.json.
My new composer.json
"require": {
"MyVendor/OtherPackage": "1.0.*",
"OtherVendor/ThridPackage":"1.0.1"
},
I am trying to install this package
ExeuAmazonECSBundle
"require": {
"php": ">=5.3.3",
.
.
.
"exeu/amazon-ecs-bundle": "dev-master"
},
then
sudo php composer.phar update exeu/amazon-ecs-bundle
However it indicates two error potential, I have confirmed it is not type.
my setting is
"minimum-stability": "alpha",
and I can install other bundle as 'dev-master'
How can I slove this?
Problem 1
- Installation request for exeu/amazon-ecs-bundle dev-master -> satisfiable by exeu/amazon-ecs-bundle[dev-master].
- exeu/amazon-ecs-bundle dev-master requires exeu/amazon-ecs-php dev-master -> no matching package found.
Problem 2
- exeu/amazon-ecs-bundle dev-master requires exeu/amazon-ecs-php dev-master -> no matching package found.
- symfony/framework-standard-edition 2.2.x-dev requires exeu/amazon-ecs-bundle dev-master -> satisfiable by exeu/amazon-ecs-bundle[dev-master].
- Installation request for symfony/framework-standard-edition 2.2.x-dev -> satisfiable by symfony/framework-standard-edition[2.2.x-dev].
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://groups.google.com/d/topic/composer-dev/_g3ASeIFlrc/discussion> for more details.
Read <http://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.
The error message is quite clear about what the problem is.
You need to contact the guy wrote that library and ask him to also publish the library 'exeu/amazon-ecs-php' which apparently 'exeu/amazon-ecs-bundle' is dependent on.
The package amazon-ecs-php isn't available in any stability, which is why composer is failing.
Hi i want to install this bundle:
https://packagist.org/packages/knplabs/knp-paginator-bundle
"knplabs/knp-paginator-bundle": "2.3.*#dev"
But i dont want to screw something with composer.phar update because last time it killed some bundles functions in FOS bundle when i remember right.
So i did only::
sudo php composer.phar install
But i got this error:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for symfony/framework-standard-edition 2.1.x-dev -> satisfiable by symfony/framework-standard-edition[2.1.x-dev].
- symfony/framework-standard-edition 2.1.x-dev requires knplabs/knp-paginator-bundle 2.3.*#dev -> 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://groups.google.com/d/topic/composer-dev/_g3ASeIFlrc/discussion> for more details.
Read <http://getcomposer.org/doc/articles/troubleshooting.md> for further common problems.
And these are my requirements for symfony and php. It should be enough right? What's the problem then please?
"require": {
"php": ">=5.3.3",
"symfony/symfony": "2.1.*",
try "minimum-stability": "dev"
see: http://getcomposer.org/doc/articles/troubleshooting.md
add the following line in your composer and update composer
"knplabs/knp-paginator-bundle": "dev-master"
I got the same. Then I tried to use php composer.phar update and it works.
Hope this will help!