doctrine / migrations

Doctrine Database Migrations Library
https://www.doctrine-project.org/projects/migrations.html
MIT License
4.65k stars 386 forks source link

Support for Symfony 5.4 broken #1387

Closed gaelreyrol closed 6 months ago

gaelreyrol commented 6 months ago

BC Break Report

Q A
BC Break yes
Version 3.7.2

Summary

Since the 3.6.0 release, the support of Symfony 5.4 is broken. The symfony/var-exporter:^7.0 package requirement makes it impossible to update this package to 3.6.0 and higher.

It is caused by this PR #1273, which implements the usage of the LazyProxyTrait from the symfony/var-exporter package in the LazySchema provider class.

In a symfony project and because of the symfony/symfony package's composer.json containing a replace section that overrides project requirements for packages mentioned in this section, it is not possible to upgrade symfony/var-exporter apart from the rest.

The composer.json stills mentions compatibility towards symfony/*:^5.4 and the drop of Symfony 5.4 was not announced in the release notes, I considered reporting this as a breaking change.

It is worth to mention that the support for Symfony is broken from version >=5.4 to <6.2 starting from the 3.6.0 release as the LazyProxyTrait is only available since its 6.2 version.

Would it be possible to support again Symfony 5.4 or do you think the support should be officially dropped?

gaelreyrol commented 6 months ago

I went too fast on the PR #1273, and did not read about the Symfony Flex recipes fix. This issue might still be useful for others encountering this issue when not using Symfony Flex.

stof commented 6 months ago

Using the symfony/symfony package is discouraged by the core team since Symfony 4.x in favor of installing the component packages. And things are only broken when using that fullstack package which cannot install different versions of components.