Closed marien-probesys closed 3 months ago
I don't see deprecations warning in the Symfony Toolbar anymore, but there are remaining issues on the CI.
I think most of them come from https://github.com/zenstruck/foundry, but I don't see any issues complaining about it, so maybe I'm doing something wrong.
I'll try to reinstall a Symfony 6.3 project from scratch with Foundry and see if I can reproduce the issue. I don't have time to do it right now, but let's see when I'll come back!
List of the deprecations.
When calling ./docker/bin/console doctrine:migrations:migrate
:
[info] User Deprecated: Subscribing to onSchemaCreateTable events is deprecated. (AbstractPlatform.php:2141 called by AbstractPlatform.php:2043, https://github.com/doctrine/dbal/issues/5784, package doctrine/dbal)
When calling ./docker/bin/console db:seeds:load
:
[info] User Deprecated: Nesting transactions without enabling savepoints is deprecated.
Call Doctrine\DBAL\Connection::setNestTransactionsWithSavepoints(true) to enable savepoints. (Connection.php:1380 called by UnitOfWork.php:424, https://github.com/doctrine/dbal/pull/5383, package doctrine/dbal)
When executing a test (mostly related to Foundry):
$ make test FILE=tests/Controller/MessageDocumentsControllerTest.php FILTER=testGetShowServesTheFile
[…]
Remaining indirect deprecation notices (35)
22x: Subscribing to onSchemaCreateTable events is deprecated. (AbstractPlatform.php:2141 called by AbstractPlatform.php:2056, https://github.com/doctrine/dbal/issues/5784, package doctrine/dbal)
11x in MessageDocumentsControllerTest::_resetDatabase from App\Tests\Controller
11x in MessageDocumentsControllerTest::_resetSchema from App\Tests\Controller
10x: Passing $sequence as a Sequence object to Doctrine\DBAL\Platforms\AbstractPlatform::getDropSequenceSQL is deprecated. Pass it as a quoted name instead. (AbstractPlatform.php:2384 called by PostgreSQLPlatform.php:802, https://github.com/doctrine/dbal/issues/4798, package doctrine/dbal)
10x in MessageDocumentsControllerTest::_resetSchema from App\Tests\Controller
2x: Nesting transactions without enabling savepoints is deprecated.
Call Doctrine\DBAL\Connection::setNestTransactionsWithSavepoints(true) to enable savepoints. (Connection.php:1380 called by UnitOfWork.php:424, https://github.com/doctrine/dbal/pull/5383, package doctrine/dbal)
2x in MessageDocumentsControllerTest::testGetShowServesTheFile from App\Tests\Controller
1x: Since doctrine/doctrine-bundle 2.2: The "Doctrine\Bundle\DoctrineBundle\Command\Proxy\RunSqlDoctrineCommand" (doctrine:query:sql) is deprecated, use dbal:run-sql command instead.
1x in MessageDocumentsControllerTest::_resetDatabase from App\Tests\Controller
None of these issues seem to be directly related to my code, so I don't know how to get rid of them unless updating the dependencies until the upstream projects fix the issues. I'm really not understanding the two first User Deprecated
issues as I don't use anything complicated.
With the last upgrades (Foundry 2, Symfony 7 and Doctrine ORM 3), it seems that all the deprecation warnings have vanished :tada:
Following https://github.com/Probesys/bileto/issues/333
To check the deprecation warnings, check for
Remaining indirect deprecation notices
in the logs of the CI.Also look for this icon in the Symfony Toolbar.