Update Extensions page error if Composer not found

Created on 20 January 2025, 1 day ago

Problem/Motivation

Installed Drupal on a shared hosting server where it couldn't find the Composer executable.
On the Extend page most tabs show an error message that Composer can't be found.

The Extend->Update Extensions tab has an uncaught exception instead.
The exception is "PhpTuf\ComposerStager\API\Exception\LogicException: The composer executable cannot be found. Make sure it's installed and in the $PATH in PhpTuf\ComposerStager\Internal\Finder\Service\ExecutableFinder->find() (line 34 of [path-to]/vendor/php-tuf/composer-stager/src/Internal/Finder/Service/ExecutableFinder.php)."

Composer is installed and was used to get the Drupal files. I don't know why it couldn't find the Composer executable, my guess is it's a permissions issue?

Steps to reproduce

Install Drupal
Make sure Composer isn't in the $PATH
Check Extend->Update for message that the Composer executable can't be found
Go to Extend->Update Extensions tab - this will give an exception

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Active

Version

11.1 πŸ”₯

Component

package_manager.module

Created by

πŸ‡¦πŸ‡ΊAustralia juxe

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024