我有一个项目要做,为了设置它,我试图使用composer install来安装并运行我的所有依赖项。问题是,当我尝试运行composer安装时,我会收到以下错误:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- The requested package sylius/sales-bundle 0.1.x-dev could not be found.
Problem 2
- Installation request for sylius/cart-bundle dev-master -> satisfiable by sylius/cart-bundle[dev-master].
- Can only install one of: sylius/resource-bundle[v0.3.0, v0.1.0].
- sylius/cart-bundle dev-master requires sylius/resource-bundle 0.3.* -> satisfiable by sylius/resource-bundle[v0.3.0].
- Installation request for sylius/resource-bundle 0.1.*@dev -> satisfiable by sylius/resource-bundle[v0.1.0].
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.
composer.json文件如下所示:
"require": {
"php": ">=5.3.3",
"symfony/symfony": "2.1.*",
"doctrine/orm": ">=2.2.3,<2.4-dev",
"doctrine/doctrine-bundle": "1.0.*",
"twig/twig": "dev-master",
"twig/extensions": "1.0.*@dev",
"symfony/assetic-bundle": "2.1.*",
"symfony/swiftmailer-bundle": "2.1.*",
"symfony/monolog-bundle": "2.1.*",
"symfony/dom-crawler": "2.1.*@dev",
"liip/doctrine-cache-bundle": "dev-master",
"sensio/distribution-bundle": "2.1.*",
"sensio/framework-extra-bundle": "2.1.*",
"sensio/generator-bundle": "2.1.*",
"kriswallsmith/assetic": "1.1.*@dev",
"apy/datagrid-bundle": "2.1.*@dev",
"bcc/cron-manager-bundle": "dev-master",
"craue/formflow-bundle": "dev-master",
"craue/config-bundle": "dev-master",
"ddeboer/data-import": "dev-master",
"phpexcel/phpexcel": "1.7.6",
"doctrine/migrations": "dev-master",
"doctrine/doctrine-migrations-bundle": "dev-master",
"elnur/blowfish-password-encoder-bundle": "dev-master",
"friendsofsymfony/user-bundle": "1.3.1",
"friendsofsymfony/message-bundle": "dev-master",
"friendsofsymfony/rest": "0.8.*@dev",
"friendsofsymfony/rest-bundle": "0.11.*@dev",
"friendsofsymfony/comment-bundle": "2.0.*@dev",
"friendsofsymfony/jsrouting-bundle": "1.1.*",
"frosas/base-url-bundle": "1.*@dev",
"genemu/form-bundle": "2.1.*",
"jms/serializer": "0.11.*@dev",
"jms/serializer-bundle": "0.11.*",
"jms/di-extra-bundle": "1.3.*@dev",
"jms/debugging-bundle": "dev-master",
"jms/job-queue-bundle": "dev-master",
"jms/payment-core-bundle": "dev-master",
"jms/security-extra-bundle": "1.4.*@dev",
"jms/twig-js": "dev-master",
"jms/twig-js-bundle": "dev-master",
"knplabs/gaufrette": "0.2.*@dev",
"knplabs/knp-gaufrette-bundle" : "dev-master",
"knplabs/knp-menu": "@dev",
"knplabs/knp-menu-bundle": "1.1.*@dev",
"knplabs/knp-snappy-bundle": "dev-master",
"knplabs/knp-time-bundle": "dev-master",
"lexik/mailer-bundle": "dev-master",
"lexik/maintenance-bundle": "dev-master",
"lexik/form-filter-bundle": "dev-master",
"pugx/multi-user-bundle": "1.3.x-dev",
"Trsteel/ckeditor-bundle": "dev-master",
"velvel/report-bundle": "dev-master",
"sonata-project/cache-bundle": "dev-master",
"sonata-project/admin-bundle": "2.1.x-dev",
"sonata-project/doctrine-orm-admin-bundle": "2.1.x-dev",
"sonata-project/jquery-bundle": "1.8.*@dev",
"sonata-project/exporter": "1.1.0",
"sonata-project/block-bundle": "2.1.x-dev",
"sonata-project/intl-bundle": "2.1.x-dev",
"sonata-project/user-bundle": "2.1.x-dev",
"sonata-project/doctrine-extensions": "1.0.0",
"sonata-project/easy-extends-bundle": "dev-master",
"sonata-project/google-authenticator": "1.0.0",
"stof/doctrine-extensions-bundle": "1.1.x-dev",
"sylius/blogger-bundle": "0.1.x-dev",
"sylius/cart-bundle": "dev-master",
"sylius/categorizer-bundle": "dev-master",
"sylius/resource-bundle": "0.1.*@dev",
"sylius/sales-bundle": "0.1.x-dev",
"white-october/pagerfanta-bundle": "2.1.x-dev as dev-master",
"pagerfanta/pagerfanta": "1.0.*@dev",
"oneup/uploader-bundle": "*",
"whiteoctober/breadcrumbs-bundle": "dev-master",
"raulfraile/ladybug-bundle": "*",
"nelmio/js-logger-bundle": "~1.0",
"nelmio/security-bundle": "~1.0",
"mtdowling/cron-expression": "1.0.x",
"liip/imagine-bundle": "dev-master",
"elao/web-profiler-extra-bundle" : "2.1.*@dev",
"elink/payment-slimcd-bundle": "2.1.*@dev",
"punkave/symfony2-file-uploader-bundle": "dev-master",
"leek/git-debug-bundle": "2.0.*@dev"
},
"scripts": {
"post-install-cmd": [
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installAssets",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile"
],
"post-update-cmd": [
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::buildBootstrap",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::clearCache",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installAssets",
"Sensio\Bundle\DistributionBundle\Composer\ScriptHandler::installRequirementsFile"
]
},
该项目使用Symfony作为框架,每次我认为我有解决方案时,都会引发其他问题。一个多小时以来,我一直在努力解决这个问题。
您应该将包括销售捆绑包在内的行替换为:"sylius/销售捆绑包":"0.2.*@dev"
当您遇到问题时,请查看packagist网站并输入捆绑包的名称。它将显示捆绑包之间的依赖关系以及版本。