Problem/Motivation

String services are deprecated as of SF 4.4. site.path is a string service created via factory in our services.yml file

Proposed resolution

Per @alexpott in #3074585-5: [Symfony 5] Replace app.root and site.path string services with container parameters

site.path is determined by the request and should be part of that system - and so should be a service of some sort with the request stack injected. One massive problem we have is that site.path determines which modules can possibly by installed and where their code is and so this does things that the Symfony container is not really optimised for.

Remaining tasks

Determine which service this should be in, whether an existing service or a new one.
Deprecate site.path
Refactor core to use the new service to retrieve the site path.

User interface changes

API changes

site.path service will be deprecated, and a replacement provided.

Data model changes

Release notes snippet

The site.path string service is now deprecated in preparation for Symfony 4 and 5 and Drupal 9

Comments

mikelutz created an issue. See original summary.

Version: 8.8.x-dev » 8.9.x-dev

Drupal 8.8.0-alpha1 will be released the week of October 14th, 2019, which means new developments and disruptive changes should now be targeted against the 8.9.x-dev branch. (Any changes to 8.9.x will also be committed to 9.0.x in preparation for Drupal 9’s release, but some changes like significant feature additions will be deferred to 9.1.x.). For more information see the Drupal 8 and 9 minor version schedule and the Allowed changes during the Drupal 8 and 9 release cycles.

mikelutz’s picture

Status: Active » Closed (duplicate)