Skip to content

Repair wp/5.5 branch Actions: Let the current Composer release install this branch's dependencies - #85004

Open
desrosj wants to merge 2 commits into
fix-actions-5.5/run-phpcs-on-runnerfrom
fix-actions-5.5/use-latest-compatible-composer
Open

desrosj wants to merge 2 commits into
fix-actions-5.5/run-phpcs-on-runnerfrom
fix-actions-5.5/use-latest-compatible-composer

Conversation

@desrosj

@desrosj desrosj commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Part of #82938.

What?

Declares config.allow-plugins in composer.json for composer/installers and dealerdirect/phpcodesniffer-composer-installer. It also pins wp-env's composer service to the composer:2 image instead of the floating composer image, with a packages/env/CHANGELOG.md entry.

Why?

Composer 2.2+ requires plugins to be allowed explicitly. Without the block, composer install fails under current Composer (exit 1):

Your composer.lock was generated before the allow-plugins security feature was introduced and your composer.json does not define allow-plugins.

--no-plugins isn't a substitute: dealerdirect/phpcodesniffer-composer-installer is what registers the PHPCS standards, and without it phpcs fails with Referenced sniff "PHPCompatibility" does not exist.

The composer image is pinned to composer:2, not to an exact release. Composer's security fixes and its advisory policy (#85005, directly above) only arrive with new releases. composer:2 still gets every Composer 2 release, including security fixes, but a future Composer 3 can't change how this branch installs its dependencies until someone updates the tag. The PHP version inside the image still follows the tag (PHP 8.5 today); that doesn't change which packages get installed, because composer.lock decides that. Nothing in that container needs an older PHP: its only job is composer install, which works on the current image (Composer 2.10.3, PHP 8.5.10). PHP_CodeSniffer, which can't run on current PHP, runs on the runner at PHP 7.4 after #85003 (directly below).

Testing

In the composer image (Composer 2.10.3, PHP 8.5.10), against this branch's composer.lock: composer install exits 0 with allow-plugins and vendor/bin/phpcs exists afterwards; without it, the install exits 1. config isn't part of the lock's content hash, so the lock doesn't change. composer:2 is currently the same image as the floating composer image, so these results apply to it.

Use of AI Tools

This PR was created by Claude Code under my supervision. All code should be treated as AI-produced and not yet reviewed by a human until this PR is marked Ready for Review.

🤖 Generated with Claude Code

@desrosj desrosj added the [Type] Build Tooling Issues or PRs related to build tooling label Oct 16, 2026
@desrosj desrosj self-assigned this Oct 16, 2026
@coderabbitai

coderabbitai Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 33c41874-2168-43b2-9ad8-19d12444562b

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: desrosj <desrosj@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@desrosj desrosj changed the title Repair wp/5.5 branch Actions: Allow Composer plugins Repair wp/5.5 branch Actions: Let the current Composer release install this branch's dependencies Oct 19, 2026
@github-actions github-actions Bot added the [Tool] Env /packages/env label Oct 23, 2026

@ntsekouras ntsekouras left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Tool] Env /packages/env [Type] Build Tooling Issues or PRs related to build tooling

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants