Due to some deprecations and the new ConnectionProvider interface we need to fix a few things to be compatible with doctrine/dbal 3.0.
See https://github.com/doctrine/dbal/pull/3956, https://github.com/doctrine/dbal/pull/4059
Also related was this fix: https://github.com/doctrine/DoctrineBundle/pull/1170
Some thoughts:
Symfony\Bridge\Doctrine\ManagerRegistry to Doctrine\DBAL\Tools\Console\ConnectionProvider and inject that into the 2 commands RunSqlDoctrineCommand and ImportDoctrineCommand (can we use the dbal commands directly and deprecate the proxy commands?)Doctrine\DBAL\Tools\Console\Helper\ConnectionHelperYes, I concluded same. But like I mentioned in #1170 I don't want to change DoctrineBundle only to find dbal changed their API before release.
@ostrolucky I think now we could work on this?
Since release 2.11 I now have some deprecations related to this on some projects:
```
Other deprecation notices (1)
1x: Not passing a connection provider as the first constructor argument is deprecated
1x in Application::run from Symfony\Bundle\FrameworkBundle\Console
Yep
Since release 2.11 I now have some deprecations related to this
It also triggers an error when using the --connection parameter:
$ bin/console doctrine:query:sql --connection=someconnection 'CREATE SCHEMA IF NOT EXISTS someschema'
In RunSqlCommand.php line 108:
Specifying a connection is only supported when a ConnectionProvider is used
With these versions:
@Adirelle indeed. I proposed a fix for that issue here: https://github.com/doctrine/DoctrineBundle/pull/1226
Fixed in master