Problem/Motivation

The 9.x pipeline #973328 fails phpstan (next major) with nullCoalesce.variable in AwsCloudConfigTest.php after PHPStan advances to 2.2.15. During MR validation, Drupal core [#3067979] also removed test files from Composer dist packages, causing next-major PHPStan and PHPUnit to fail with missing test classes.

Proposed resolution

Initialize the selected region code to an empty string before the selection loops and pass it directly to the cloud-context helper. Until a tagged GitLab template release includes the upstream prefer-source fix, fetch that fix for the next-major Composer job so Drupal core test classes remain available.

Issue fork cloud-3625500

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

ai_yas created an issue. See original summary.

ai_yas’s picture

I opened MR!2397 for 9.x. It initializes $selected_region_code before the selection loops and removes the redundant ?? '' at the call site. PHP syntax and the regular PHPStan job pass. The merged-results pipeline #974143 has next-major failures: PHPStan reports more than 1,000 missing Drupal test API errors, and PHPUnit cannot load Drupal\TestTools\TestRunner\Configuration. I am leaving the issue at Needs work until CI passes.

ai_yas’s picture

Issue summary: View changes
Status: Needs work » Needs review

I updated MR!2397 for 9.x. The next-major CI failure was caused by Drupal core [#3067979] excluding tests from Composer dist packages. The MR now fetches the merged GitLab template fix until it is released in a tag. Merged-results pipeline #975599 passes regular and next-major Composer, PHPStan, and PHPUnit, as well as PHPCS, Composer lint, ESLint, and Stylelint. The next-major Composer artifact contains web/core/tests. Moving this issue to Needs review.

ai_yas’s picture

Follow-up on MR!2397: I removed the pinned GitLab template commit. The next-major Composer job now follows the upstream main branch until the recommended template tag includes the prefer-source fix. Merged-results pipeline #975649 passes regular and next-major Composer, PHPStan, and PHPUnit, plus PHPCS, Composer lint, ESLint, and Stylelint. The temporary override can be removed once a tagged template release contains the fix.

yas’s picture

Status: Needs review » Reviewed & tested by the community

@ai_yas, you can merge MR!2397 into 9.x and close this issue as Fixed.

ai_yas’s picture

Status: Reviewed & tested by the community » Fixed

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.

  • ai_yas committed f91124a4 on 9.x
    fix: #3625500 Fix PHPStan next-major warning in AWS Cloud config test on...

Status: Fixed » Closed (fixed)

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