From 78d252789ce0d22a862411232e6aa58854d83b83 Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Wed, 11 Jun 2025 18:13:59 -0700 Subject: [PATCH] Setup: Update error message for composer dependencies check == Why == While psr/log represents our original an first use of Composer, this is nowadays "just" another dependency among many. It does not justify or help understand what to do next. == What == Use the same "external libraries" terminology, as on mediawiki.org. == History == * 2014 (Ie66794441): Add first ever Composer dependency (psr/log) * 2015 (Ie47467657): Add LoggerFactory with check for missing Composer dependency, to address a then-common issue. * 2015 (Ib60261237): Move check earlier, to WebStart. * 2017 (I633a6ff23): Move check earlier, to Setup. * 2021 (Ia81903fb2): Remove redundant exit(1). * 2025 (I6050ec4ca): Replace deprecated E_USER_ERROR. Change-Id: I890d1f285997ccbc04cdb378a69815982c2bf64f (cherry picked from commit b538453cdc6438419d044854cc730706988cb908) --- includes/Setup.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/Setup.php b/includes/Setup.php index 8e819fd42d0..cbe9ad6cc2d 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -129,12 +129,12 @@ require_once MW_INSTALL_PATH . '/includes/Defines.php'; // Assert that composer dependencies were successfully loaded if ( !interface_exists( LoggerInterface::class ) ) { $message = ( - 'Error: MediaWiki requires the PSR-3 logging ' . - "library to be present. This library is not embedded directly in MediaWiki's " . - "git repository and must be installed separately by the end user.\n\n" . + 'Error: Missing external libraries. ' . + 'MediaWiki depends on external libraries bundled with most MediaWiki distributions. ' . + "When installing MediaWiki from its Git reposistory, these must be installed separately.\n\n" . 'Please see the instructions for installing libraries on mediawiki.org ' . - 'for help on installing the required components.' + 'for help on installing the required libraries.' ); http_response_code( 500 ); echo $message;