Problem/Motivation

Drupal 11.2 recommends PHP 8.3, but PHP 8.4 has been available for nearly a year. Core currently only has two known bugs being tracked for PHP 8.4 compatibility, one of which is merely a deprecation warning and another of which is a whitespace issue.

Proposed resolution

Recommend PHP 8.4 in 11.3.

Remaining tasks

User interface changes

The administrative UI will present the usual information about PHP 8.4 being the recommended version depending on the installed PHP version of the site host.

Release notes snippet

PHP 8.4 is now the recommended PHP version for sites using Drupal 11.3 and above.

Issue fork drupal-3554384

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

xjm created an issue. See original summary.

xjm’s picture

Status: Active » Needs review
xjm’s picture

Version: 11.3.x-dev » 11.x-dev

Ahem.

xjm changed the visibility of the branch 3554384-php-84 to hidden.

xjm’s picture

Title: Recommend PHP 8.4 for Drupal 11.3 » Recommend PHP 8.4 for Drupal 11.3 and 10.6

We should do this for both actually, since D10 also has no compatibility issues.

lostcarpark’s picture

Makes sense.

Although, when I install on 8.4, I still get a bunch of deprecation warnings from contrib modules.

xjm’s picture

@lostcarpark, we don't block core on contrib. It's contrib's responsibility to stay up to date with core. :) Drupal 11 has been compatible with PHP 8.4 since 11.1 and the PHP 8.4 pipeline has been been available and passing with without deprecation warnings on core since before then, so it's high time to recommend the rest of the ecosystem follow suit.

Hopefully increasing this will encourage contrib to get updated. I imagine also switching over the default CI pipeline at some point will help.

lostcarpark’s picture

I fully agree, and I wasn't suggesting that should be a blocker.

smustgrave’s picture

Do we often change recommendation mid major? For 12 makes sense but seems odd for 11 and 10 just my thought

mstrelan’s picture

Major is for updating the minimum supported version, no harm in changing a recommendation. I'm sure it happened several times throughout the 7.x and 8.x lifecycle.

xjm’s picture

longwave’s picture

Status: Needs review » Reviewed & tested by the community

We made a similar change in Drupal 10.2: #3397110: Increase RECOMMENDED_PHP to 8.2 for Drupal 10.2 and again in 10.3: #3446936: Recommend PHP 8.3 in Drupal 10.3

Note that this isn't changing the minimum supported version, just that we recommend users go to 8.4; we will possible require 8.5 for Drupal 12 depending on what Symfony decides to do, so better to nudge users to newer versions now if we can.

  • catch committed 1a64d315 on 11.3.x
    Issue #3554384 by xjm: Recommend PHP 8.4 for Drupal 11.3 and 10.6
    
    (...

  • catch committed b83498f4 on 10.6.x
    Issue #3554384 by xjm: Recommend PHP 8.4 for Drupal 11.3 and 10.6
    
    (...

  • catch committed 4270d378 on 11.x
    Issue #3554384 by xjm: Recommend PHP 8.4 for Drupal 11.3 and 10.6
    
catch’s picture

Version: 11.x-dev » 10.6.x-dev
Status: Reviewed & tested by the community » Fixed

Committed/pushed to 11.x and cherry-picked to 11.3.x and 10.6.x, thanks!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

xjm’s picture

Added credit for @longwave for documenting the standard practice with our previous issues.

xjm’s picture

Added to the 11.3.0, 11.3.0-beta1, 10.6.0, and 10.6.0-beta1 release notes drafts.

tobiasb’s picture

fyi: It was only set to 8.4 not 8.4.0. The other issues set it to 8.2.0/8.3.0.

xjm’s picture

@tobiasb This was deliberate on my part. 8.2.0/8.3.0 was overly specific and done probably by reflex, rather than for any valid reason. We should only specify a patch version if we know we require or recommend a specific patch version (for example, if there is a bug fix in a previous patch version affecting us and we recommend e.g. 8.4.2 or something).

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.