Drupal 8.5.x now uses a minimum of Symfony 3.4.x.
All Symfony components in Drupal 8.5.x have been updated to 3.4.x, this is the last release in the 3.x cycle for Symfony. Symfony 3.4 is a long-term support release and we expect to remain on 3.4 releases for the rest of Drupal 8's support lifetime.
The following API breaks have been identified and fixed in Drupal core:
Private/public services
As of Symfony 3.4, all services are marked as private. Normal services declared via *.services.yml
files are automatically marked as public (unless explicitly declared private). Services declared via ServiceProviderInterface
and ServiceModifierInterface
classes should mark themselves as public if this is the intent:
$my_service = new Definition(Foo::class);
$my_service->setPublic(TRUE);
$container->setDefinition('my_service', $my_service);
Deprecations
The following new deprecations occurred between symfony 3.2 and 3.4. Individual change-notices will be issued as Drupal is updated to remove interactions with these deprecated APIs.
- The Symfony\Component\ClassLoader\ApcClassLoader was deprecated and will be removed before Drupal 9, #2937534: Bring the Symfony\Component\ClassLoader\ApcClassLoader into core and undeprecate will address that.
- The Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher class is deprecated since Symfony 3.3 and will be removed before Drupal 9.0 - #2937537: Remove uses of Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher from core will address that.
- The Symfony\Component\HttpFoundation\Session\Storage\Handler\WriteCheckSessionHandler class is deprecated since Symfony 3.4 and will be removed in 4.0. #2937540: Remove usages of Symfony\Component\HttpFoundation\Session\Storage\Handler\WriteCheckSessionHandler
- The "session_handler.write_check" service relies on the deprecated "Symfony\Component\HttpFoundation\Session\Storage\Handler\WriteCheckSessionHandler" class. #2937541: [PP-1] The "session_handler.write_check" service relies on the deprecated WriteCheckSessionHandler class
- Not setting the strict option of the Choice constraint to true is deprecated since Symfony 3.4 and will throw an exception in 4.0 #2937542: Not setting the strict option of the Choice constraint to true is deprecated since Symfony 3.4 and will throw an exception in 4.0.
- Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0 #2937543: Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0.
- Meta for removing technical debt related to deprecations: #2959269: [meta] Core should not trigger deprecated code except in tests and during updates
Relevant Symfony links: