Skip to content

Commit 4786a74

Browse files
Merge branch '7.2' into 7.3
* 7.2: [DoctrineBridge] Fix Connection::createSchemaManager() for Doctrine DBAL v2 CS: re-apply trailing_comma_in_multiline [HttpClient] Various cleanups after recent changes chore: fix some typos do not add child nodes to EmptyNode instances consider write property visibility to decide whether a property is writable Fix merge add comment explaining why HttpClient tests are run separately [HttpClient] Fix computing stats for PUSH with Amp silence warnings issued by Redis Sentinel on connection issues Revert "[FrameworkBundle] Deprecate making `cache.app` adapter taggable"
2 parents 5a90414 + ddebd80 commit 4786a74

33 files changed

+160
-180
lines changed

.github/workflows/windows.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ jobs:
111111
Remove-Item -Path src\Symfony\Bridge\PhpUnit -Recurse
112112
mv src\Symfony\Component\HttpClient\phpunit.xml.dist src\Symfony\Component\HttpClient\phpunit.xml
113113
php phpunit src\Symfony --exclude-group tty,benchmark,intl-data,network,transient-on-windows || ($x = 1)
114+
# HttpClient tests need to run separately, they block when run with other components' tests concurrently
114115
php phpunit src\Symfony\Component\HttpClient || ($x = 1)
115116
116117
exit $x
@@ -124,6 +125,7 @@ jobs:
124125
125126
Copy c:\php\php.ini-max c:\php\php.ini
126127
php phpunit src\Symfony --exclude-group tty,benchmark,intl-data,network,transient-on-windows || ($x = 1)
128+
# HttpClient tests need to run separately, they block when run with other components' tests concurrently
127129
php phpunit src\Symfony\Component\HttpClient || ($x = 1)
128130
129131
exit $x

.php-cs-fixer.dist.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
'@Symfony:risky' => true,
3333
'protected_to_private' => false,
3434
'header_comment' => ['header' => $fileHeaderComment],
35-
'trailing_comma_in_multiline' => ['elements' => ['arrays', 'match', 'parameters']],
3635
])
3736
->setRiskyAllowed(true)
3837
->setFinder(

UPGRADE-7.2.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ Cache
1212
-----
1313

1414
* `igbinary_serialize()` is not used by default when the igbinary extension is installed
15-
* Deprecate making `cache.app` adapter taggable, use the `cache.app.taggable` adapter instead
1615

1716
Console
1817
-------

src/Symfony/Bridge/Doctrine/SchemaListener/AbstractSchemaListener.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,7 @@ abstract public function postGenerateSchema(GenerateSchemaEventArgs $event): voi
2424
protected function getIsSameDatabaseChecker(Connection $connection): \Closure
2525
{
2626
return static function (\Closure $exec) use ($connection): bool {
27-
$schemaManager = $connection->createSchemaManager();
28-
27+
$schemaManager = method_exists($connection, 'createSchemaManager') ? $connection->createSchemaManager() : $connection->getSchemaManager();
2928
$checkTable = 'schema_subscriber_check_'.bin2hex(random_bytes(7));
3029
$table = new Table($checkTable);
3130
$table->addColumn('id', Types::INTEGER)

src/Symfony/Bridge/Twig/NodeVisitor/TranslationDefaultDomainNodeVisitor.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
use Symfony\Bridge\Twig\Node\TransNode;
1616
use Twig\Environment;
1717
use Twig\Node\BlockNode;
18+
use Twig\Node\EmptyNode;
1819
use Twig\Node\Expression\ArrayExpression;
1920
use Twig\Node\Expression\AssignNameExpression;
2021
use Twig\Node\Expression\ConstantExpression;
@@ -75,6 +76,12 @@ public function enterNode(Node $node, Environment $env): Node
7576

7677
if ($node instanceof FilterExpression && 'trans' === ($node->hasAttribute('twig_callable') ? $node->getAttribute('twig_callable')->getName() : $node->getNode('filter')->getAttribute('value'))) {
7778
$arguments = $node->getNode('arguments');
79+
80+
if ($arguments instanceof EmptyNode) {
81+
$arguments = new Nodes();
82+
$node->setNode('arguments', $arguments);
83+
}
84+
7885
if ($this->isNamedArguments($arguments)) {
7986
if (!$arguments->hasNode('domain') && !$arguments->hasNode(1)) {
8087
$arguments->setNode('domain', $this->scope->get('domain'));

src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2398,11 +2398,6 @@ private function registerCacheConfiguration(array $config, ContainerBuilder $con
23982398
];
23992399
}
24002400
foreach ($config['pools'] as $name => $pool) {
2401-
if (\in_array('cache.app', $pool['adapters'] ?? [], true) && $pool['tags']) {
2402-
trigger_deprecation('symfony/framework-bundle', '7.2', 'Using the "tags" option with the "cache.app" adapter is deprecated. You can use the "cache.app.taggable" adapter instead (aliased to the TagAwareCacheInterface for autowiring).');
2403-
// throw new LogicException('The "tags" option cannot be used with the "cache.app" adapter. You can use the "cache.app.taggable" adapter instead (aliased to the TagAwareCacheInterface for autowiring).');
2404-
}
2405-
24062401
$pool['adapters'] = $pool['adapters'] ?: ['cache.app'];
24072402

24082403
$isRedisTagAware = ['cache.adapter.redis_tag_aware'] === $pool['adapters'];

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/php/cache_cacheapp_tagaware.php

Lines changed: 0 additions & 16 deletions
This file was deleted.

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/xml/cache_cacheapp_tagaware.xml

Lines changed: 0 additions & 15 deletions
This file was deleted.

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/yml/cache_cacheapp_tagaware.yml

Lines changed: 0 additions & 11 deletions
This file was deleted.

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/FrameworkExtensionTestCase.php

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313

1414
use Psr\Cache\CacheItemPoolInterface;
1515
use Psr\Log\LoggerAwareInterface;
16-
use Symfony\Bridge\PhpUnit\ExpectUserDeprecationMessageTrait;
1716
use Symfony\Bundle\FrameworkBundle\DependencyInjection\FrameworkExtension;
1817
use Symfony\Bundle\FrameworkBundle\FrameworkBundle;
1918
use Symfony\Bundle\FrameworkBundle\Tests\Fixtures\Messenger\DummyMessage;
@@ -96,8 +95,6 @@
9695

9796
abstract class FrameworkExtensionTestCase extends TestCase
9897
{
99-
use ExpectUserDeprecationMessageTrait;
100-
10198
private static array $containerCache = [];
10299

103100
abstract protected function loadFromFile(ContainerBuilder $container, $file);
@@ -1856,16 +1853,6 @@ public function testCacheTaggableTagAppliedToPools()
18561853
}
18571854
}
18581855

1859-
/**
1860-
* @group legacy
1861-
*/
1862-
public function testTaggableCacheAppIsDeprecated()
1863-
{
1864-
$this->expectUserDeprecationMessage('Since symfony/framework-bundle 7.2: Using the "tags" option with the "cache.app" adapter is deprecated. You can use the "cache.app.taggable" adapter instead (aliased to the TagAwareCacheInterface for autowiring).');
1865-
1866-
$this->createContainerFromFile('cache_cacheapp_tagaware');
1867-
}
1868-
18691856
/**
18701857
* @dataProvider appRedisTagAwareConfigProvider
18711858
*/

0 commit comments

Comments
 (0)