Add an API for dynamically setting recommended and supported PHP versions based on known and predicted PHP release schedules

Created on 31 January 2022, almost 3 years ago
Updated 18 January 2023, almost 2 years ago

Problem/Motivation

See discussion from #3223443-24: [policy, no patch] Process for dealing with EOL PHP versions during the Drupal 10 and future release cycles β†’ on.

Proposed resolution

  • Deprecate \Drupal::MINIMUM_SUPPORTED_PHP in favor of a methods that returns our best estimate for the given date, based on our release schedule and PHP's known (and predicted) release cycles.
  • Hardcode safe estimates in 10.0.0, and patch the methods in each minor with updated estimates.

Note that this approach only makes sense if we issue a warning on installation (rather than an error) as discussed in #2917655: [9.4.x only] Drop official PHP 7.3 support in Drupal 9.4 β†’ .

Remaining tasks

TBD

User interface changes

Users on old PHP versions automatically begin seeing new informational messages or warnings on a given date, even if they are not running the latest Drupal minor.

API changes

\Drupal::MINIMUM_SUPPORTED_PHP is deprecated in favor of \Drupal\Core\PhpRequirements::minimumSupportedPhp().

Data model changes

Probably none?

Release notes snippet

The minimum supported PHP version is now set dynamically based on the predicted end-of-life date. After PHP version is no longer supported there will be a warning about unsupported PHP version but this won't prevent running, updating, or installing Drupal.

πŸ“Œ Task
Status

Fixed

Version

9.4

Component
BaseΒ  β†’

Last updated about 7 hours ago

Created by

πŸ‡ΊπŸ‡ΈUnited States xjm

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024