Closed fabriciojs closed 5 years ago
This is the same issue here https://github.com/symfony-cmf/block-bundle/issues/289 .
@dbu said:
could you do a pull request to add a conflicts section for cache >2.99 that we can put into 2.1? and if you have the time, prepare a pull request to upgrade the cacheintegration to sonata 3?
I will try providing such PRs today. Looking at https://github.com/symfony-cmf/block-bundle/blob/2.x/src/Cache/BlockJsCache.php on branch 2.x
I see it still does not comply with the new interface (missing the type hints). I believe the target branch should be that one, then when merged could generate release 2.2?
Let me know if I should go anyway differently about this. Thanks!
Yes that is is an issue. But the issue was in one our two minor versions of sonata-project/block-bundle
, where they introduced BC breaks instead of the deprecation notices. If you want to get a really save sonata version you should use block-bundle from ^3.15.0
, cause there also a strictness fix is included.
So how to solve:
either move the broken versions (3.12 and 3.13 from my POV) to your own conflicts or we should do it on block-bundle and release a patch. I also prepare a new minor version, where I dropped all smaler block-bundle-versions: #298
And the caching thing is an other issue. There i would recommend to move "sonata-project/cache": "<1.1.1"
into conflicts and require "sonata-project/cache-bundle": "2.4.*"
. The 3.x versions there are not compatible atm. The got the BC-Breaks you currently see.
@ElectricMaxxx thanks for the quick response!
I have managed it to work with the suggested requirement changes:
- "sonata-project/cache-bundle": "^3.0",
+ "sonata-project/block-bundle": "^3.15.0",
+ "sonata-project/cache": "^1.0",
+ "sonata-project/cache-bundle": "2.4.*",
Thanks a lot!
A thought though: should the block-bundle error out and not install, due to the known mismatched versions? By changing the conflict section as suggested by David a while back like:
Environment
Upgrading a CMF application from Symfony 2.8 top 3.4.
Sonata packages
Symfony packages
PHP version
Subject
With the given set of dependencies properly installed via composer, I get a mismatch on the
Sonata\Cache\CacheAdapterInterface
interface - which does not belong to this project, but the dependencies resolution allowed it to be installed along, which I believe should be fixed upon this bug report.Steps to reproduce
Installing a Symfony 3.4 application and requesting all the packages listed above, ended up with a mismatch on the
sonata/cache
package version that added a BC by changing such interface.Expected results
Should either install a locked/earlier version, or just conflict and say that it cannot install due to conflicting versions.
Actual results