Sean Breeden

Full Stack PHP, Python, AI/ML Developer
""You miss 100% of the shots you don't take. -- Wayne Gretzky"" --Michael Scott

Magento 2.4.2-p2 update failed during composer update

Tuesday, October 12th, 2021

After trying to update to Magento 2.4.2-p2, you may receive some output like the following:

$ composer update

The "dealerdirect/phpcodesniffer-composer-installer" plugin was skipped because it requires a Plugin API version ("^1.0") that does not match your Composer installation ("2.0.0"). You may need to run composer update with the "--no-plugins" option.

Loading composer repositories with package information

In Laminas\DependencyPlugin\DependencyRewriterV2::onPrePoolCreate

Updating dependencies

Your requirements could not be resolved to an installable set of packages.

Problem 1

- Root composer.json requires dealerdirect/phpcodesniffer-composer-installer ^0.5.0 -> satisfiable by dealerdirect/phpcodesniffer-composer-installer[v0.5.0].

- dealerdirect/phpcodesniffer-composer-installer v0.5.0 requires composer-plugin-api ^1.0 -> found composer-plugin-api[2.0.0] but it does not match the constraint.

You are using Composer 2, which some of your plugins seem to be incompatible with. Make sure you update your plugins or report a plugin-issue to ask them to support Composer 2.

The fix:

$ composer require --dev dealerdirect/phpcodesniffer-composer-installer:"^0.7.0"

Thanks to https://github.com/Dealerdirect/phpcodesniffer-composer-installer/issues/119#issuecomment-716625149 !

Views: 2030
| Home | Announcements | Artificial Intelligence | Commodore 64 | CraftCMS | Crypto | Games | Geek | Machine Learning | Magento | Memes | Science News | Security | 7 Days to Die | Ubuntu |