mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
cli-config.php compatibility with DBAL #6566
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @PowerKiKi on GitHub (Nov 4, 2020).
Since DBAL 2.11.0 and https://github.com/doctrine/dbal/pull/3956, it is now deprecated to use HelperSet in
cli-config.php. This will become impossible in DBAL 3, following https://github.com/doctrine/dbal/pull/4059.This means that, in order to keep sharing a single config file for both packages, this package should also accept the new
\Doctrine\DBAL\Tools\Console\ConnectionProvider. It could actually be a new interface along the lines of:I suppose the support of HelperSet could be drop entirely in the next major version too. So long we can use a
HelperSetManagerProviderthat extends theEntityManagerProvider.All commands must be adjusted to access the entity manager from a provider instead of the HelperSet. Deprecation messages when using HelperSet must be thrown appropriately.
See related https://github.com/doctrine/migrations/issues/1070
@beberlei commented on GitHub (Mar 6, 2021):
I have updated the description of the issue to explain my approach to performing this deprecation:
EntityManagerProvideras mentionedHelperSetManagerProviderthat is used and introduced for the deprecated legacy case inConsoleRunnerAbstractEntityManagerCommandthat each command implements. Provide backwards compatibility with other packages extending Doctrine commands.@beberlei commented on GitHub (Apr 18, 2021):
Merged #8524 into 2.9.x