Skip to content

fix: pin Drush below 15 so Drupal 12 workspaces finish setup - #250

Merged
rfay merged 1 commit into
mainfrom
20261116_rfay_pin_drush
Nov 16, 2026
Merged

rfay merged 1 commit into
mainfrom
20261116_rfay_pin_drush

Conversation

@rfay

@rfay rfay commented Nov 16, 2026

Copy link
Copy Markdown
Member

Short Summary (TL;DR)

Drupal 12 workspaces hang after "✓ Drush installed", because Drush 15.x-dev now ships a drush stub that calls itself forever. The templates now require drush/drush:<15, which gives Drupal 12 Drush 14.x and leaves Drupal 11 on Drush 13.

The Issue

Since the 2026-11-16 nightly run, every Drupal 12 job in the Drupal and Drupal Contrib integration tests fails. The workspace setup logs ✓ Drush installed, prints nothing for about 20 minutes, then the job fails with agent is shutting down. Drupal 11 jobs still pass.

On 2026-11-16 at 02:31 UTC, Drush's 15.x branch landed drush-ops/drush#6673, "Remove most of Drush. Most commands remain callable via Drupal core's dr". It replaced vendor/drush/drush/drush with:

#!/usr/bin/env sh

echo "Instead of calling `drush`, call `dr`" >&2
exit 1

The backticks inside double quotes run drush as a command substitution, so every drush call starts another drush, and none of them ever returns. The setup's next step, ddev drush status, never finishes.

ddev composer require drush/drush has no version constraint. Drush 15.x-dev conflicts with drupal/core < 12.0, so Drupal 12 gets 15.x-dev and Drupal 11 gets 13.x.

How This PR Solves The Issue

Every place that adds Drush now requires drush/drush:<15:

File Change
drupal-core/template.tf ddev composer require "drush/drush:<15"
drupal-core/scripts/test-issue-branches.sh Same
drupal-contrib/template.tf require-dev value "<15" instead of "*"
drupal-contrib/scripts/test-issue-branches.sh composer require --dev "drush/drush:<15"
drupal-core/README.md Same command in the manual instructions

Drush 14.x-dev only conflicts with drupal/core < 11.3, so it supports Drupal 12. Drupal 11 still resolves to Drush 13.8.x, the newest stable release.

Moving Drupal 12 to Drupal core's dr command is a separate, larger change.

Manual Testing Instructions

Create a Drupal 12 workspace from this branch's template on staging:

coder create d12-drush-test --template drupal-core --use-parameter-defaults \
  --parameter "vscode_extensions=[]" --parameter drupal_version=12 \
  --parameter issue_fork= --parameter issue_branch= --parameter install_profile=minimal \
  --parameter drupal_site_public=false --yes
coder ssh d12-drush-test -- tail -5 /tmp/drupal-setup.log
# Expect the setup to continue past "✓ Drush installed" and finish the site install
coder ssh d12-drush-test -- 'cd ~/drupal-core && ddev composer show drush/drush | grep versions'
# Expect "versions : * 14.x-dev"
coder delete d12-drush-test --yes

Automated Testing Overview

  • Claude Code reproduced the hang on staging-coder.ddev.com with a Drupal 12 workspace from main. Composer installed 15.x-dev at commit 942cf6c, and ps showed sh .../vendor/drush/drush/drush processes starting again and again.
  • Claude Code ran terraform fmt -recursive -check, make validate and make test-templates, which passed with 22 tests.
  • This PR's Drupal and Drupal Contrib integration runs exercise the fix on Drupal 12.

🤖 Generated with Claude Code

## Short Summary (TL;DR)

Drupal 12 workspaces hang after "✓ Drush installed", because Drush 15.x-dev now ships a `drush` stub that calls itself forever. The templates now require `drush/drush:<15`, which gives Drupal 12 Drush 14.x and leaves Drupal 11 on Drush 13.

## The Issue

Since the 2026-11-16 nightly run, every Drupal 12 job in the Drupal and Drupal Contrib integration tests fails. The workspace setup logs `✓ Drush installed`, prints nothing for about 20 minutes, then the job fails with `agent is shutting down`. Drupal 11 jobs still pass.

On 2026-11-16 at 02:31 UTC, Drush's `15.x` branch landed drush-ops/drush#6673, "Remove most of Drush. Most commands remain callable via Drupal core's `dr`". It replaced `vendor/drush/drush/drush` with:

```sh
#!/usr/bin/env sh

echo "Instead of calling `drush`, call `dr`" >&2
exit 1
```

The backticks inside double quotes run `drush` as a command substitution, so every `drush` call starts another `drush`, and none of them ever returns. The setup's next step, `ddev drush status`, never finishes.

`ddev composer require drush/drush` has no version constraint. Drush 15.x-dev conflicts with `drupal/core` < 12.0, so Drupal 12 gets 15.x-dev and Drupal 11 gets 13.x.

## How This PR Solves The Issue

Every place that adds Drush now requires `drush/drush:<15`:

| File | Change |
| --- | --- |
| `drupal-core/template.tf` | `ddev composer require "drush/drush:<15"` |
| `drupal-core/scripts/test-issue-branches.sh` | Same |
| `drupal-contrib/template.tf` | `require-dev` value `"<15"` instead of `"*"` |
| `drupal-contrib/scripts/test-issue-branches.sh` | `composer require --dev "drush/drush:<15"` |
| `drupal-core/README.md` | Same command in the manual instructions |

Drush 14.x-dev only conflicts with `drupal/core` < 11.3, so it supports Drupal 12. Drupal 11 still resolves to Drush 13.8.x, the newest stable release.

Moving Drupal 12 to Drupal core's `dr` command is a separate, larger change.

## Manual Testing Instructions

Create a Drupal 12 workspace from this branch's template on staging:

```bash
coder create d12-drush-test --template drupal-core --use-parameter-defaults \
  --parameter "vscode_extensions=[]" --parameter drupal_version=12 \
  --parameter issue_fork= --parameter issue_branch= --parameter install_profile=minimal \
  --parameter drupal_site_public=false --yes
coder ssh d12-drush-test -- tail -5 /tmp/drupal-setup.log
# Expect the setup to continue past "✓ Drush installed" and finish the site install
coder ssh d12-drush-test -- 'cd ~/drupal-core && ddev composer show drush/drush | grep versions'
# Expect "versions : * 14.x-dev"
coder delete d12-drush-test --yes
```

## Automated Testing Overview

- Claude Code reproduced the hang on staging-coder.ddev.com with a Drupal 12 workspace from `main`. Composer installed `15.x-dev` at commit 942cf6c, and `ps` showed `sh .../vendor/drush/drush/drush` processes starting again and again.
- Claude Code ran `terraform fmt -recursive -check`, `make validate` and `make test-templates`, which passed with 22 tests.
- This PR's Drupal and Drupal Contrib integration runs exercise the fix on Drupal 12.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Previews

The start.coder.ddev.com landing-page preview has been removed. Read the Docs keeps or removes its own docs preview.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant