I had a development site still on 8.8.0. I updated it using composer require 'drupal/core-recommended:^8.9' --update-with-all-dependencies, as per instructions; it worked, but it only went to 8.9.0-beta2.

This is what I got:

$ COMPOSER_MEMORY_LIMIT=-1 composer require 'drupal/core-recommended:8.9.0' --update-with-all-dependencies
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Can only install one of: symfony/polyfill-php72[v1.17.0, v1.14.0].
    - Can only install one of: symfony/polyfill-php72[v1.17.0, v1.14.0].
    - Can only install one of: symfony/polyfill-php72[v1.17.0, v1.14.0].
    - drupal/core-recommended 8.9.0 requires symfony/polyfill-php72 v1.17.0 -> satisfiable by symfony/polyfill-php72[v1.17.0].
    - Installation request for drupal/core-recommended 8.9.0 -> satisfiable by drupal/core-recommended[8.9.0].
    - Installation request for symfony/polyfill-php72 (locked at v1.14.0) -> satisfiable by symfony/polyfill-php72[v1.14.0].

Installation failed, reverting ./composer.json to its original content.

So, there is a conflict between three packages with exactly the same name and version? How is this possible and how can I fix it?

  • 6
    Packages can't share names, so you can assume that's just the output of 3 requests to verify the same package during the update. Something is locking the php72 polyfill to 1.14, which conflicts with what you're otherwise asking it to do. Usually it's easy to force this through: composer update drupal/core-recommended symfony/polyfill-php72 --with-dependencies
    – Clive
    Jun 10, 2020 at 14:06
  • 1
    Yes, many thanks! Forcing symfony/polyfill worked, I did something slightly different because I feared the command you suggested would upgrade the core to 9.0 that I'm not ready for, so I did composer update symfony/polyfill-php72 --with-dependencies followed by composer require 'drupal/core-recommended:8.9.0' --update-with-all-dependencies, and it worked flawlessly. Still, may be because I am used to apt, I am surprised that a single user request may lead to three underlying conflicting requests :( Jun 10, 2020 at 14:55
  • 1
    It'll be the same conflict reported 3 times, one for each dependency that couldn't resolve it, something like that.I wouldn't get too disheartened, you're not alone; I've been using Composer for many years and it still frustrates the life out of me!
    – Clive
    Jun 10, 2020 at 19:00
  • 1
    You're telling me. I was getting crazy because the upgrade I did yesterday, from 8.8.0 to 8.9.0, only presented the conflict above; today I tried to repeat it on another instance, from 8.8.2 to 8.9.0, and fell right in dependency hell, until a quick search showed mw I could just copy composer.json from the instance I upgraded yesterday and run a composer install. Jun 11, 2020 at 8:13
  • 1
    We need to see your composer.json to tell for sure
    – leymannx
    Apr 6, 2021 at 6:42


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.