Allow composer/installers v2 - #6
Open
svandragt wants to merge 1 commit into
Open
Conversation
The plugin works with either major version, so pinning to `~1.0` blocks the sites that install it. composer/installers v1.12 emits a PHP 8.4 deprecation notice on every Composer command, and a site cannot move to v2 while any package in the tree still requires v1. The lockfile keeps its current v1 entry, so nothing changes for anyone until they update. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016bJCbjM6ym1P1D4oHbFGYo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Allow
composer/installersv2 alongside v1.What changes
composer.jsonwidens the constraint from~1.0to^1.0 || ^2.0. The plugin uses composer/installers only to place itself inwp-content/plugins, which both major versions do the same way, so the pin to v1 buys nothing and costs the sites that install it.composer/installers v1.12 emits a PHP 8.4 deprecation notice on every Composer command. A site cannot move to v2 while any package in its tree still requires v1, and this plugin is one of the packages holding wikimediafoundation.org back.
What this does not change
The lockfile keeps its current v1 entry, so nothing moves for anyone until they run an update. Its content hash is now stale against
composer.json;composer installwarns but still installs from the lock, and refreshing it is left out on purpose:composer update --lockalso rewrites the PHP_CodeSniffer repository URL and some empty-array serialisation, churn from a newer Composer version that has nothing to do with this change.Testing
composer installpasses with the widened constraint. Onlycomposer.jsonchanges, so there is nothing for PHPCS to check.🤖 Generated with Claude Code
https://claude.ai/code/session_016bJCbjM6ym1P1D4oHbFGYo