Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/json/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 无法在Symfony2 2.4中安装SonataUserBundle_Php_Json_Symfony_Composer Php_Sonata User Bundle - Fatal编程技术网

Php 无法在Symfony2 2.4中安装SonataUserBundle

Php 无法在Symfony2 2.4中安装SonataUserBundle,php,json,symfony,composer-php,sonata-user-bundle,Php,Json,Symfony,Composer Php,Sonata User Bundle,我无法使用symfony2.4安装sonata项目/用户包。Composer给了我这样的错误消息: Problem 1 - Conclusion: remove symfony/symfony v2.4.0 - Installation request for symfony/framework-standard-edition 2.4.x-dev -> satisfiable by symfony/framework-standard-edition[2.4.x-de

我无法使用symfony2.4安装sonata项目/用户包。Composer给了我这样的错误消息:

  Problem 1
    - Conclusion: remove symfony/symfony v2.4.0
    - Installation request for symfony/framework-standard-edition 2.4.x-dev -> satisfiable by symfony/framework-standard-edition[2.4.x-dev].
    - Conclusion: don't install symfony/symfony v2.4.0
    - Installation request for sonata-project/user-bundle 2.2.2 -> satisfiable by sonata-project/user-bundle[2.2.2].
    - Installation request for friendsofsymfony/user-bundle ~2.0@dev -> satisfiable by friendsofsymfony/user-bundle[2.0.x-dev].
    - symfony/framework-standard-edition 2.4.x-dev requires sensio/framework-extra-bundle ~3.0 -> satisfiable by sensio/framework-extra-bundle[v3.0.0].
    - sensio/framework-extra-bundle v3.0.0 requires symfony/framework-bundle ~2.4 -> satisfiable by symfony/symfony[v2.4.0], symfony/framework-bundle[v2.4.0].
    - sensio/framework-extra-bundle v3.0.0 requires symfony/framework-bundle ~2.4 -> satisfiable by symfony/symfony[v2.4.0], symfony/framework-bundle[v2.4.0].
    - Conclusion: don't install symfony/framework-bundle v2.4.0
My composer.json:

{
    "name": "symfony/framework-standard-edition",
    "license": "MIT",
    "type": "project",
    "description": "The \"Symfony Standard Edition\" distribution",
    "autoload": {
    "psr-0": { "": "src/" }
    },
    "require": {
    "php": ">=5.3.3",
    "symfony/symfony": "2.*",
    "doctrine/orm": "~2.2,>=2.2.3",
    "doctrine/doctrine-bundle": "~1.2",
    "twig/extensions": "~1.0",
    "symfony/assetic-bundle": "~2.3",
    "symfony/swiftmailer-bundle": "~2.3",
    "symfony/monolog-bundle": "~2.4",
    "sensio/distribution-bundle": "~2.3",
    "sensio/framework-extra-bundle": "~3.0",
    "sensio/generator-bundle": "~2.3",
    "incenteev/composer-parameter-handler": "~2.0",
    "friendsofsymfony/user-bundle": "~2.0@dev",
    "stof/doctrine-extensions-bundle": "~1.1@dev",
    "sonata-project/admin-bundle": "~2.1",
    "sonata-project/doctrine-orm-admin-bundle": "~2.1",
    "sonata-project/user-bundle": "2.2.2",
    "knplabs/knp-paginator-bundle": "2.3.*",
    "knplabs/knp-menu-bundle": "1.1.*",
    "knplabs/knp-menu": "1.1.*"

    },
    "scripts": {
    "post-install-cmd": [
        "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
        "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": [
        "Incenteev\\ParameterHandler\\ScriptHandler::buildParameters",
        "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"
    },
    "extra": {
    "symfony-app-dir": "app",
    "symfony-web-dir": "web",
    "incenteev-parameters": {
        "file": "app/config/parameters.yml"
    },
    "branch-alias": {
        "dev-master": "2.4-dev"
    }
    }
}
当我从composer.json中删除行sonata项目/用户包:2.2.2时,composer更新运行平稳

sonata用户[2.2.2]是否与Symfony2.4不兼容?我找不到任何官方信息

我成功安装了chceck composer.json od SonataUserBundle和SonataAdminBundle,它们都需要symfony/httpfoundation:~2.2,所以我真的没有主意了

更新

github中的票证

通过修改composer.json更改friendsofsymfony/user捆绑包的版本-

"friendsofsymfony/user-bundle": "1.3.3",
并发出命令:

composer update
在Symfony 2.4.0上为我工作过好消息

我已经添加了修复程序,使SonataUserBundle能够与FOSUserBundle 2.0一起工作*


有临时安排吗?没有。。。我刚刚从sonata用户包辞职,并编写了自己的用户类实现、用户管理等。。。我在我的描述中添加了github票证链接。希望它能在一段时间内提供解决方案。我会在2014年1月6日之后尝试。谢谢你的回复。我设法安装了它,谢谢。不幸的是,我不会在当前项目中使用它。已经实施了用户管理。但这对未来来说是有用的。我希望版本2.*将很快与sf2.4+兼容+1我接受这个答案,因为installine sonata user bundle 2.2*目前似乎不可能实现,而您的解决方案是我找到的唯一安装sonata user bundle的方法。在Symfony 2.6上工作后,我可以看到,不幸的是,它无法到达主机。但是谢谢你的努力。