Rvanlaak
Rvanlaak

Reputation: 3085

Composer unable to resolve sylius/settings-bundle

I'm unable to resolve the Sylius settings bundle correctly. My application is a Symfony standard application. According to the default json of Symfony 2.4.4 the requirement is doctrine/doctrine-bundle ~1.2

My current json: https://gist.github.com/Rvanlaak/f627a73a8d431600f8ba

Resolving sylius/settings-bundle ~0.9 gives me the following error:

- Installation request for doctrine/doctrine-bundle == 1.2.0.0 -> satisfiable by doctrine/doctrine-bundle[v1.2.0].
- Conclusion: don't install doctrine/doctrine-bundle 1.3.x-dev
- sylius/settings-bundle v0.9.0 requires sylius/resource-bundle 0.9.*@dev -> satisfiable by sylius/resource-bundle[v0.9.0].
- sylius/settings-bundle 0.10.x-dev requires sylius/resource-bundle 0.10.*@dev -> satisfiable by sylius/resource-bundle[0.10.x-dev].
- sylius/resource-bundle v0.9.0 requires doctrine/doctrine-bundle ~1.3@dev -> satisfiable by doctrine/doctrine-bundle[1.3.x-dev, v1.3.0-beta1].
- sylius/resource-bundle 0.10.x-dev requires doctrine/doctrine-bundle ~1.3@dev -> satisfiable by doctrine/doctrine-bundle[1.3.x-dev, v1.3.0-beta1].
- Conclusion: don't install doctrine/doctrine-bundle v1.3.0-beta1
- Installation request for sylius/settings-bundle ~0.9 -> satisfiable by sylius/settings-bundle[0.10.x-dev, v0.9.0].

Changing my doctrine/doctrine-bundle to ~1.3@dev or 1.2.0 gives the error:

- The requested package doctrine/doctrine-bundle == 1.2.0.0 could not be found.

And therafter require sylius/settings-bundle dev-master gives the error:

- Can only install one of: doctrine/doctrine-bundle[1.3.x-dev, v1.2.0].
- Can only install one of: doctrine/doctrine-bundle[v1.2.0, 1.3.x-dev].
- sylius/resource-bundle 0.10.x-dev requires doctrine/doctrine-bundle ~1.3@dev -> satisfiable by doctrine/doctrine-bundle[1.3.x-dev].
- sylius/settings-bundle dev-master requires sylius/resource-bundle 0.10.*@dev -> satisfiable by sylius/resource-bundle[0.10.x-dev].
- Installation request for sylius/settings-bundle dev-master -> satisfiable by sylius/settings-bundle[dev-master].
- Installation request for doctrine/doctrine-bundle v1.2.0 -> satisfiable by doctrine/doctrine-bundle[v1.2.0].

So to me it looks like the dependencies contradict eachother. Is Symfony standard edition unable to resolve the sylius/settings-bundle ?

EDIT

After removing the following bundles composer actually resolves correctly

    "lexik/form-filter-bundle" : "~2.0",
    "knplabs/knp-paginator-bundle" : "~2.3",
    "liip/imagine-bundle" : "<1.0.x-dev",
    "raulfraile/ladybug-bundle" : "~1.0",
    "simplethings/entity-audit-bundle" : "~0.5",
    "knplabs/knp-snappy-bundle" : "~1.1",
    "fpn/tag-bundle": "~0.9"

Upvotes: 1

Views: 576

Answers (2)

Valentino Chet
Valentino Chet

Reputation: 1

Set all Sylius bundles to version 0.9. And you have no coflicts

Upvotes: 0

albertedevigo
albertedevigo

Reputation: 18411

Sylius dependencies are a complete mess these days (it is a pre-alpha release). There is no good solution at the moment, but if you use

"minimum-stability": "dev",
"prefer-stable": true,

in your composer.json you probably will get what you expect.

That installs Doctrine 1.3.0@dev, that is not compatible with Symfony 2.4. So Doctrine code generators (app/console doctrine:...) will implode, but Sylius will work.

As I said, at the moment there's not an optimal solution, maybe with Symfony 2.5.

Upvotes: 1

Related Questions