Hi, I was using a Drupal 10 site without installation problem, then I tried to install the alpha of Drupal 11 since I am starting a new site.

The Drupal 11-alpha went good but as soon as I tried to install drush to complete the setup, I got error of incompatibilities. I also tried

composer require --no-cache -W drush/drush:*

with the following error:

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

Problem 1
- drupal/core 11.0.0-alpha1 conflicts with drush/drush 6.7.0.
- drupal/core 11.0.0-alpha1 conflicts with drush/drush 6.1.0.
- drush/drush 13.0.0-beta1 requires chi-teck/drupal-code-generator ^3 || 4.x-dev -> satisfiable by chi-teck/drupal-code-generator[3.0.0-alpha1, ..., 3.5.0].
- drupal/action 0.2.1 requires drupal/core >10.2 -> satisfiable by drupal/core[11.0.0-alpha1].
- drush/drush[7.0.0-alpha1, ..., 7.0.0-alpha4] require symfony/yaml 2.2.1 -> found symfony/yaml[v2.2.1] but these were not loaded, likely because it conflicts with another require.
- drush/drush[7.0.0-alpha5, ..., 7.1.0, 8.0.0-beta11, ..., 8.0.0-rc2] require symfony/yaml ~2.2 -> found symfony/yaml[v2.2.0, ..., v2.8.52] but these were not loaded, likely because it conflicts with another require.
- drush/drush[7.2.0, ..., 7.4.2, 8.0.2, ..., 8.4.12, 9.0.0-alpha1, ..., 9.0.0-beta7, 10.3.6, ..., 10.6.2, 11.0.0-rc1, ..., 11.0.5] require psr/log ~1.0 -> found psr/log[1.0.0, ..., 1.1.4] but these were not loaded, likely because it conflicts with another require.
- drush/drush[8.0.0-rc3, ..., 8.0.1] require symfony/yaml 2.7.* -> found symfony/yaml[v2.7.0-BETA1, ..., v2.7.51] but these were not loaded, likely because it conflicts with another require.
- drush/drush[9.0.0-beta8, ..., 9.7.3, 10.0.0-alpha1, ..., 10.3.5] require composer/semver ^1.4 -> found composer/semver[1.4.0, ..., 1.7.2] but these were not loaded, likely because it conflicts with another require.
- drush/drush[11.0.6, ..., 11.6.0] require symfony/event-dispatcher ^4.0 || ^5.0 || ^6.0 -> found symfony/event-dispatcher[v4.0.0-BETA1, ..., v4.4.44, v5.0.0-BETA1, ..., v5.4.39, v6.0.0-BETA1, ..., v6.4.7] but these were not loaded, likely because it conflicts with another require.
- drush/drush 12.0.0-beta1 requires consolidation/annotated-command 4.x-dev -> found consolidation/annotated-command[4.x-dev] but it does not match your minimum-stability.
- drush/drush[12.0.0-rc1, ..., 12.5.2] require symfony/event-dispatcher ^6 -> found symfony/event-dispatcher[v6.0.0-BETA1, ..., v6.4.7] but these were not loaded, likely because it conflicts with another require.
- chi-teck/drupal-code-generator[3.0.0-alpha1, ..., 3.0.0-beta2] require symfony/console ^6.0 -> found symfony/console[v6.0.0-BETA1, ..., v6.4.7] but these were not loaded, likely because it conflicts with another require.
- chi-teck/drupal-code-generator[3.0.0-beta3, ..., 3.0.0] require symfony/console ^6.2 -> found symfony/console[v6.2.0-BETA1, ..., v6.4.7] but these were not loaded, likely because it conflicts with another require.
- chi-teck/drupal-code-generator[3.1.0, ..., 3.5.0] require symfony/console ^6.3 -> found symfony/console[v6.3.0-BETA1, ..., v6.4.7] but these were not loaded, likely because it conflicts with another require.
- drupal/action is locked to version 0.2.1 and an update of this package was not requested.
- Root composer.json requires drush/drush * -> satisfiable by drush/drush[6.0.0-rc1, ..., 6.7.0, 7.0.0-alpha1, ..., 7.4.2, 8.0.0-beta11, ..., 8.4.12, 9.0.0-alpha1, ..., 9.7.3, 10.0.0-alpha1, ..., 10.6.2, 11.0.0-rc1, ..., 11.6.0, 12.0.0-beta1, ..., 12.5.2, 13.0.0-beta1].

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

What should I do to overcome the problem? I am on Rocky Linux 9.4

Thanks a lot

Giuse

Comments

jaypan’s picture

Seems like Drush may not be compatible with Drupal 11 yet.

When you're working with an alpha version, you're pretty much on your own, as pretty much no one else will be using Drupal 11 yet, and will run into plenty of issues like this with incompatibilities.

You can get more info about what's preventing the upgrade with: composer prohibits drush/drush 13

Contact me to contract me for D7 -> D10/11 migrations.

jvandyk’s picture

Things are moving fast. Currently with Drupal 11.0.0-beta1 you can mess with Drush 13 by telling composer that the 13 betas are ok.

composer require drush/drush:^13.0@beta chi-teck/drupal-code-generator:4.x-dev

Edit: now that Drupal 11 and Drush 13 are released you can just use

composer require drush/drush:^13

trevorbradley’s picture

Verified that requiring chi-teck/drupal-code-generator:4.x-dev will get around the issue - just be sure to clean up when Drupal 11 and Drush 13 go live. 

ressa’s picture

Thanks @jvandyk! Your tip works perfectly. I created the issue Cannot install Drush in Drupal 11 #6032 so that maybe it can get fixed at some point.

ressa’s picture

A new official release of Chi-teck's Drupal Code Generator will probably solve this problem, see Release new version, to allow installing Drush in Drupal 11 #177.

joemueller7788@gmail.com’s picture

Hi giuse,
I am also facing the same issue on the my drupal. This problem is occuring with me again and again.