Problem/Motivation

Using the latest dev on PHP 8.4, I'm getting this deprecation warning:

PHP Deprecated:  Drupal\email_registration\Plugin\Action\UpdateUsernameAction::access(): Implicitly marking parameter $account as nullable is deprecated, the explicit nullable type must be used instead in /var/www/html/web/modules/contrib/email_registration/src/Plugin/Action/UpdateUsernameAction.php on line 68
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

ptmkenny created an issue. See original summary.

ptmkenny changed the visibility of the branch fix_php8.4_deprecation to hidden.

ptmkenny’s picture

Status: Active » Needs review

For some reason it's not letting me create an MR off the branch at the moment, but I'm setting this to "Needs review" because the change is fixed in the php84deprecation branch.

uttam’s picture

Assigned: Unassigned » uttam

uttam’s picture

Assigned: uttam » Unassigned
uttam’s picture

I have tried to raise the MR for in my case also the pipeline is failed and the below are the failed jobs:

composer (max PHP version)
      .git/**/*: excluded 75 files                       
Uploading artifacts as "archive" to coordinator... 201 Created  id=4263642 responseStatus=201 Created token=glcbt-64
Uploading artifacts...
build.env: found 1 matching artifact files and directories 
Uploading artifacts as "dotenv" to coordinator... 201 Created  id=4263642 responseStatus=201 Created token=glcbt-64

Cleaning up project directory and file based variables

ERROR: Job failed: command terminated with exit code 1


    
composer
 .git/**/*: excluded 75 files                       
Uploading artifacts as "archive" to coordinator... 201 Created  id=4263534 responseStatus=201 Created token=glcbt-64
Uploading artifacts...
build.env: found 1 matching artifact files and directories 
Uploading artifacts as "dotenv" to coordinator... 201 Created  id=4263534 responseStatus=201 Created token=glcbt-64

Cleaning up project directory and file based variables

ERROR: Job failed: command terminated with exit code 1


    
composer (next minor)
  .git/**/*: excluded 75 files                       
Uploading artifacts as "archive" to coordinator... 201 Created  id=4263533 responseStatus=201 Created token=glcbt-64
Uploading artifacts...
build.env: found 1 matching artifact files and directories 
Uploading artifacts as "dotenv" to coordinator... 201 Created  id=4263533 responseStatus=201 Created token=glcbt-64

Cleaning up project directory and file based variables

ERROR: Job failed: command terminated with exit code 1


    
composer (previous minor)
      .git/**/*: excluded 75 files                       
Uploading artifacts as "archive" to coordinator... 201 Created  id=4263523 responseStatus=201 Created token=glcbt-64
Uploading artifacts...
build.env: found 1 matching artifact files and directories 
Uploading artifacts as "dotenv" to coordinator... 201 Created  id=4263523 responseStatus=201 Created token=glcbt-64

Cleaning up project directory and file based variables

ERROR: Job failed: command terminated with exit code 1
ptmkenny’s picture

@uttam You can confirm that the tests are already broken on the module page: https://www.drupal.org/project/email_registration. So that's why you're seeing that error.

ptmkenny changed the visibility of the branch 3504702-depreciationerror to hidden.

acbramley’s picture

Title: UpdateUsernameAction::access() Implicitly marking parameter $account as nullable is deprecated » Fix implicit nullables for PHP 8.4
Status: Needs review » Needs work

CI is being fixed in #3507612: Fix CI on 2.x HEAD there are a few other implicit nullables to fix here

acbramley’s picture

Status: Needs work » Needs review
grevil’s picture

Status: Needs review » Reviewed & tested by the community

Yep, that should be all, thanks again! LGTM! 🎉

grevil’s picture

Status: Reviewed & tested by the community » Fixed

All green. Merging.

  • grevil committed fad0efcb on 2.x authored by ptmkenny
    Issue #3504702 by ptmkenny, acbramley: Fix implicit nullables for PHP 8....

Status: Fixed » Closed (fixed)

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