在安装Doctrine Migration时出现依赖混淆



我正在尝试安装doctrine-migrations-bundle,并且我得到一个您的要求无法解决为一组可安装的软件包,这里是日志

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  
   - Conclusion: remove symfony/symfony 2.1.x-dev  
   - Conclusion: don't install symfony/symfony 2.1.x-dev  
   - Conclusion: don't install symfony/symfony v2.1.9  
   - Conclusion: don't install symfony/symfony v2.1.8  
   - Conclusion: don't install symfony/symfony v2.1.7  
   - Conclusion: don't install symfony/symfony v2.1.6  
   - Conclusion: don't install symfony/symfony v2.1.5  
   - Conclusion: don't install symfony/symfony v2.1.4  
   - Conclusion: don't install symfony/symfony v2.1.3  
   - Conclusion: don't install symfony/symfony v2.1.2  
   - Conclusion: don't install symfony/symfony v2.1.1  
   - Conclusion: don't install symfony/symfony v2.1.0  
   - Conclusion: don't install symfony/symfony v2.1.0-RC2  
   - Conclusion: don't install symfony/symfony v2.1.0-RC1  
   - Conclusion: don't install symfony/symfony v2.1.0-BETA4  
   - Installation request for doctrine/doctrine-migrations-bundle dev-master -> satisfiable by doctrine/doctrine-migrations-bundle dev-master.  
   - Conclusion: don't install symfony/symfony v2.1.0-BETA3  
   - Installation request for symfony/config dev-master -> satisfiable by symfony/config dev-master, symfony/symfony dev-master, symfony/symfony 2.3.x-dev.  
   - Conclusion: don't install symfony/symfony v2.1.0-BETA2  
   - doctrine/doctrine-migrations-bundle dev-master requires symfony/framework-bundle >=2.1.0,<2.3-dev -> satisfiable by symfony/symfony 2.1.x-dev, symfony/symfony 2.1.x-dev, symfony/symfony 2.2.x-dev, symfony/symfony v2.1.0, symfony/symfony v2.1.1, symfony/symfony v2.1.2, symfony/symfony v2.1.3, symfony/symfony v2.1.4, symfony/symfony v2.1.5, symfony/symfony v2.1.6, symfony/symfony v2.1.7, symfony/symfony v2.1.8, symfony/symfony v2.1.9, symfony/symfony v2.2.0, symfony/symfony v2.2.0-BETA1, symfony/symfony v2.2.0-BETA2, symfony/symfony v2.2.0-RC1, symfony/symfony v2.2.0-RC2, symfony/symfony v2.2.0-RC3, symfony/symfony v2.2.1, symfony/framework-bundle 2.1.x-dev, symfony/framework-bundle 2.2.x-dev, symfony/framework-bundle v2.1.0, symfony/framework-bundle v2.1.1, symfony/framework-bundle v2.1.2, symfony/framework-bundle v2.1.3, symfony/framework-bundle v2.1.4, symfony/framework-bundle v2.1.5, symfony/framework-bundle v2.1.6, symfony/framework-bundle v2.1.7, symfony/framework-bundle v2.1.8, symfony/framework-bundle v2.1.9, symfony/framework-bundle v2.2.0, symfony/framework-bundle v2.2.0-BETA1, symfony/framework-bundle v2.2.0-BETA2, symfony/framework-bundle v2.2.0-RC1, symfony/framework-bundle v2.2.0-RC2, symfony/framework-bundle v2.2.0-RC3, symfony/framework-bundle v2.2.1.  
   - Can only install one of: symfony/symfony v2.1.0-BETA1, symfony/symfony 2.2.x-dev.  
   - Can only install one of: symfony/symfony v2.2.0, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.0-BETA1, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.0-BETA2, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.0-RC1, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.0-RC2, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.0-RC3, symfony/symfony v2.1.0-BETA1.  
   - Can only install one of: symfony/symfony v2.2.1, symfony/symfony v2.1.0-BETA1.  
   - don't install symfony/framework-bundle 2.2.x-dev|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.1|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle 2.1.x-dev|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.0|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.1|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.2|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.3|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.4|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.5|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.6|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.7|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.8|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.1.9|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0-BETA1|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0-BETA2|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0-RC1|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0-RC2|don't install symfony/symfony v2.1.0-BETA1  
   - don't install symfony/framework-bundle v2.2.0-RC3|don't install symfony/symfony v2.1.0-BETA1  
   - Installation request for symfony/symfony 2.1.* -> satisfiable by symfony/symfony 2.1.x-dev, symfony/symfony v2.1.0, symfony/symfony v2.1.0-BETA1, symfony/symfony v2.1.0-BETA2, symfony/symfony v2.1.0-BETA3, symfony/symfony v2.1.0-BETA4, symfony/symfony v2.1.0-RC1, symfony/symfony v2.1.0-RC2, symfony/symfony v2.1.1, symfony/symfony v2.1.2, symfony/symfony v2.1.3, symfony/symfony v2.1.4, symfony/symfony v2.1.5, symfony/symfony v2.1.6, symfony/symfony v2.1.7, symfony/symfony v2.1.8, symfony/symfony v2.1.9.
这是我的composer.json
{
    "name": "symfony/framework-standard-edition",
    "description": "The "Symfony Standard Edition" distribution",
    "autoload": {
        "psr-0": {
            "": "src/"
        }
    },
    "require": {
        "php": ">=5.3.2",
        "symfony/symfony": "2.1.*",
        "doctrine/orm": ">=2.2.3,<2.4-dev",
        "doctrine/doctrine-bundle": "1.0.*",
        "doctrine/doctrine-migrations-bundle": "dev-master",
        "twig/extensions": "1.0.*",
        "symfony/assetic-bundle": "2.1.*",
        "symfony/swiftmailer-bundle": "2.1.*",
        "symfony/monolog-bundle": "2.1.*",
        "sensio/distribution-bundle": "2.1.*",
        "sensio/framework-extra-bundle": "2.1.*",
        "sensio/generator-bundle": "2.1.*",
        "jms/security-extra-bundle": "1.2.*",
        "jms/di-extra-bundle": "1.1.*",
        "sonata-project/user-bundle": "dev-master",
        "sonata-project/admin-bundle": "dev-master",
        "sonata-project/doctrine-orm-admin-bundle": "dev-master",
        "isoft/mssql-bundle": "master-dev",
        "sonata-project/cache-bundle": "dev-master",
    "symfony/config": "dev-master"
    },
    "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"
        ]
    },
    "config": {
        "bin-dir": "bin"
    },
    "minimum-stability": "dev",
    "extra": {
        "symfony-app-dir": "app",
        "symfony-web-dir": "web",
        "symfony-assets-install": "symlink"
    }
}

I never understand composer log.

谁能帮我破译这个错误,这样我就能知道我做错了什么?

我今天试图安装doctrine/doctrine-migrations-bundle有类似的问题。我将把我的答案留在这里,因为虽然解决办法很简单,但我在其他地方没有找到。

就像我们需要doctrine/ormdoctrine/doctrine-bundle一样,我们需要 doctrine/migrations doctrine/doctrine-migrations-bundle

所以,也包括在你的composer.json:

{
    "require": {
        "doctrine/migrations": "dev-master",
        "doctrine/doctrine-migrations-bundle": "dev-master"
    }
}

我现在已经能够用packagist

修复这种错误了

您不能要求symfony/config dev-master symfony/symfony 2.1,因为主包替换了其他包。如果你把symfony/config改成2.1.*,效果可能会更好。

相关内容

  • 没有找到相关文章

最新更新