Closed TangMonk closed 6 years ago
The problem is:
sonata-project/core-bundle 3.7.1 requires sonata-project/datagrid-bundle ^2.0
However datagrid-bundle
has a require line "symfony/dependency-injection": "^2.8 || ^3.2",
But you have symfony/dependency-injection v4.0.0
installed so it can't install a <4.x version over it.
So the fault is at datagrid-bundle
to "workaround" this, you must manually install ^3.4 version of dependency injection. composer require symfony/dependency-injection:"^3.4"
But of course you should upgrade when the issue is fixed.
I reported the issue to SonataGridBundle
You will still have problems with missing configurations etc. unfortunately SonataAdmin seem to be completely incompatible with Symfony4. You shouldn't use SonataAdmin.
You will still have problems with missing configurations etc. unfortunately SonataAdmin seem to be completely incompatible with Symfony4. You shouldn't use SonataAdmin.
Which, honestly applies to 95% of the symfony bundles. It's a complete new major version, released just 2 weeks ago. Don't expect bundles to update that much code that quickly.
Try to imagine spending 2 hours a day, outside your working hours, on typing PHP code for others. Then imagine someone saying "Oh god, you're useless, not caring about others and not updating your bundle. I'll use another one.". Then rethink your attitude. Thanks!
@TangMonk The Sonata Project is not yet supporting Symfony 4 fully (this bundle seems to, but dependencies aren't yet). As far as I can see, the Sonata team and its contributors are close to releasing Symfony 4 support for the final bundles.
For now, I recommend you to stick with Symfony 3.4, which has excatly the same features as 4.0. When, in some days to some weeks, all bundles support Symfony 4, you can update to 4.0 directly without any problems. (that is, if you make sure not to have any deprecated feature usages in your Symfony 3.4 code).
thanks!
Thanks for the support @wouterj 👍
Yeah thanks a lot @wouterj , you really hit the nail on the head! Here is a small comic to lighten up the mood:
This is no longer an issue, maybe it cannot be installed using flex (by the moment), but it can be done, see #4910
Environment
macOS 10.12 Composer 1.5.5 Symfony framework 4
Sonata packages
Symfony packages
PHP version
Subject
Cannot install sonata-project/admin-bundle
Steps to reproduce
Expected results
install success
Actual results