Score:0

Composer upgrade to 9.4.x fails, my site is stuck on 9.3.x

tz flag

My Drupal 9 site is stuck on the 9.3.x track, I cannot upgrade to 9.4.x. If I use the standard upgrade command:

composer update "drupal/core-*" --with-all-dependencies

Then it upgrades to the latest 9.3 version (currently 9.3.22), but no further.

If I try to force to 9.4.7 (or any 9.4.x version) with:

composer require drupal/core-recommended:9.4.7 drupal/core-composer-scaffold:9.4.7 drupal/core-project-message:9.4.7 --update-with-all-dependencies

This fails with the composer error

Problem 1 - Root composer.json requires drupal/core-recommended 9.4.7 -> satisfiable by drupal/core-recommended[9.4.7]. - drupal/core-recommended 9.4.7 requires drupal/core 9.4.7 -> found drupal/core[9.4.7] but these were not loaded, likely because it conflicts with another require.

If I try to find out why:

composer prohibits drupal/core 9.4.7

then I get:

drupal/core-recommended 9.3.22 requires drupal/core (9.3.22)

drupal/mysql56 1.3.0 requires drupal/core (~9.0.0-beta3 || 9.1.* || 9.2.* || 9.3.*)

drupal/core 9.4.7 requires symfony/polyfill-iconv (^1.25)

drupal/legacy-project dev-main does not require symfony/polyfill-iconv (but v1.23.0 is installed)

drupal/core 9.4.7 requires symfony/polyfill-php80 (^1.25)

drupal/legacy-project dev-main does not require symfony/polyfill-php80 (but v1.23.1 is installed)

drupal/core 9.4.7 requires laminas/laminas-feed (^2.17)

drupal/legacy-project dev-main does not require laminas/laminas-feed (but 2.15.0 is installed)

drupal/core 9.4.7 requires egulias/email-validator (^2.1.22|^3.2)

drupal/legacy-project dev-main does not require egulias/email-validator (but 3.1.2 is installed)

drupal/core 9.4.7 requires composer/semver (^3.3)

drupal/legacy-project dev-main does not require composer/semver (but 3.2.6 is installed)

Should I also include all these in the composer statement? I have tried:

lando composer require drupal/core-recommended:9.4.7 drupal/core-composer-scaffold:9.4.7 drupal/core-project-message:9.4.7 symfony/polyfill-iconv laminas/laminas-feed egulias/email-validator composer/semver --update-with-all-dependencies

But this gives similar Problem 1 as before.

Any help much appreciated.

As requested, here is the composer.json file in full:

{
    "name": "drupal/legacy-project",
    "description": "Project template for Drupal 9 projects with composer following drupal/drupal layout",
    "type": "project",
    "license": "GPL-2.0-or-later",
    "homepage": "https://www.drupal.org/project/drupal",
    "support": {
        "docs": "https://www.drupal.org/docs/user_guide/en/index.html",
        "chat": "https://www.drupal.org/node/314178"
    },
    "repositories": [
        {
            "type": "composer",
            "url": "https://packages.drupal.org/8"
        }
    ],
    "require": {
        "composer/installers": "^1.9",
        "cweagans/composer-patches": "^1.7",
        "drupal/administerusersbyrole": "^3.2",
        "drupal/anchor_link": "^2.5",
        "drupal/autologout": "^1.4",
        "drupal/ckeditor_resize": "^1.3",
        "drupal/core-composer-scaffold": "^9.3",
        "drupal/core-project-message": "^9.3",
        "drupal/core-recommended": "^9.3",
        "drupal/core-vendor-hardening": "^9.3",
        "drupal/csv_serialization": "^2.1",
        "drupal/ctools": "^3.11",
        "drupal/embed": "^1.6",
        "drupal/entity_browser": "^2.8",
        "drupal/entityreference_filter": "^1.4",
        "drupal/field_group": "^3.3",
        "drupal/field_permissions": "^1.2",
        "drupal/google_analytics": "^3.1",
        "drupal/insert_view": "^2.0",
        "drupal/juicebox": "^3.0@alpha",
        "drupal/linkit": "^5.0@beta",
        "drupal/login_history": "^1.1",
        "drupal/mail_login": "^2.6",
        "drupal/media_directories": "^2.0",
        "drupal/media_library_edit": "^2.3",
        "drupal/menu_breadcrumb": "^1.16",
        "drupal/menu_position": "1.x-dev",
        "drupal/mysql56": "^1.3",
        "drupal/pathauto": "^1.11",
        "drupal/redirect": "^1.8",
        "drupal/role_watchdog": "^2.0",
        "drupal/roleassign": "^1.0@beta",
        "drupal/security_review": "^1.0@alpha",
        "drupal/tabtamer": "2.x-dev@dev",
        "drupal/token": "^1.11",
        "drupal/token_filter": "^1.4",
        "drupal/views_data_export": "^1.1",
        "drupal/webform": "^6.1",
        "drush/drush": "^11.0",
        "mikehaertl/phpwkhtmltopdf": "~2.1",
        "tecnickcom/tcpdf": "~6"
    },
    "conflict": {
        "drupal/drupal": "*"
    },
    "minimum-stability": "stable",
    "prefer-stable": true,
    "config": {
        "sort-packages": true,
        "allow-plugins": {
            "composer/installers": true,
            "cweagans/composer-patches": true,
            "drupal/core-composer-scaffold": true,
            "drupal/core-project-message": true,
            "drupal/core-vendor-hardening": true
        },
        "process-timeout": 0
    },
    "extra": {
        "drupal-scaffold": {
            "locations": {
                "web-root": "./"
            }
        },
        "installer-paths": {
            "core": [
                "type:drupal-core"
            ],
            "libraries/{$name}": [
                "type:drupal-library"
            ],
            "modules/contrib/{$name}": [
                "type:drupal-module"
            ],
            "profiles/contrib/{$name}": [
                "type:drupal-profile"
            ],
            "themes/contrib/{$name}": [
                "type:drupal-theme"
            ],
            "drush/Commands/contrib/{$name}": [
                "type:drupal-drush"
            ],
            "modules/custom/{$name}": [
                "type:drupal-custom-module"
            ],
            "profiles/custom/{$name}": [
                "type:drupal-custom-profile"
            ],
            "themes/custom/{$name}": [
                "type:drupal-custom-theme"
            ]
        },
        "drupal-core-project-message": {
            "include-keys": [
                "homepage",
                "support"
            ],
            "post-create-project-cmd-message": [
                "<bg=blue;fg=white>                                                         </>",
                "<bg=blue;fg=white>  Congratulations, you’ve installed the Drupal codebase  </>",
                "<bg=blue;fg=white>  from the drupal/legacy-project template!               </>",
                "<bg=blue;fg=white>                                                         </>",
                "",
                "<bg=yellow;fg=black>Next steps</>:",
                "  * Install the site: https://www.drupal.org/docs/8/install",
                "  * Read the user guide: https://www.drupal.org/docs/user_guide/en/index.html",
                "  * Get support: https://www.drupal.org/support",
                "  * Get involved with the Drupal community:",
                "      https://www.drupal.org/getting-involved",
                "  * Remove the plugin that prints this message:",
                "      composer remove drupal/core-project-message"
            ]
        },
        "enable-patching": true,
        "patches": {
            "drupal/core": {
                "Arbitrary sizing of media - images for CKEditor: https://www.drupal.org/project/drupal/issues/3132211": "https://www.drupal.org/files/issues/2021-12-08/3132211_drupal_media_ckeditor_resize_17.patch"
            }
        }
    }
}
id flag
It is very difficult to provide package manager support without seeing the configuration file. Please also include the composer.json file in your question.
SI_2000 avatar
tz flag
I have received -2 votes, I don't understand why, so please help me to improve my question (as cilefen did), happy to provide whatever additional information is needed here.
Score:2
id flag

The cause appears to be:

drupal/mysql56 1.3.0 requires drupal/core (~9.0.0-beta3 || 9.1.* || 9.2.* || 9.3.*)

That unsupported version of drupal/mysql56 does not allow Drupal 9.4 or higher.

SI_2000 avatar
tz flag
Many thanks cilefen for helping me understand this message. I used the following command and it successfully upgraded: lando composer require drupal/core-recommended:9.4.7 drupal/core-composer-scaffold:9.4.7 drupal/core-project-message:9.4.7 drupal/mysql56 --update-with-all-dependencies
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.