From f2dae7c8c1a60a84446ac000276f0d53057e262a Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Wed, 25 Oct 2023 12:26:10 +0200 Subject: [PATCH] Increase the system requirements for MariaDB to 10.5.15 The versions 10.5.12 and 10.5.13 (10.5.14 was never released) contain a bug that breaks window functions when the SQL mode `ONLY_FULL_GROUP_BY` is set. --- .../update_com.woltlab.wcf_6.0_checkSystemRequirements.php | 2 +- .../lib/acp/form/PackageEnableUpgradeOverrideForm.class.php | 4 ++-- wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php | 2 +- wcfsetup/install/files/lib/system/WCFSetup.class.php | 4 ++-- wcfsetup/test.php | 4 ++-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/wcfsetup/install/files/acp/update_com.woltlab.wcf_6.0_checkSystemRequirements.php b/wcfsetup/install/files/acp/update_com.woltlab.wcf_6.0_checkSystemRequirements.php index ebc19001a6..456b31019b 100644 --- a/wcfsetup/install/files/acp/update_com.woltlab.wcf_6.0_checkSystemRequirements.php +++ b/wcfsetup/install/files/acp/update_com.woltlab.wcf_6.0_checkSystemRequirements.php @@ -45,7 +45,7 @@ if (!\extension_loaded('intl')) { $sqlVersion = WCF::getDB()->getVersion(); $compareSQLVersion = \preg_replace('/^(\d+\.\d+\.\d+).*$/', '\\1', $sqlVersion); if (\stripos($sqlVersion, 'MariaDB') !== false) { - $neededSqlVersion = '10.5.12'; + $neededSqlVersion = '10.5.15'; $sqlFork = 'MariaDB'; } else { $sqlFork = 'MySQL'; diff --git a/wcfsetup/install/files/lib/acp/form/PackageEnableUpgradeOverrideForm.class.php b/wcfsetup/install/files/lib/acp/form/PackageEnableUpgradeOverrideForm.class.php index db63ab158e..cc9083fac9 100644 --- a/wcfsetup/install/files/lib/acp/form/PackageEnableUpgradeOverrideForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/PackageEnableUpgradeOverrideForm.class.php @@ -226,13 +226,13 @@ final class PackageEnableUpgradeOverrideForm extends AbstractFormBuilderForm if (\stripos($sqlVersion, 'MariaDB') !== false) { $databaseName = "MariaDB {$compareSQLVersion}"; - $expectedVersion = '10.5.12'; + $expectedVersion = '10.5.15'; $alternativeDatabase = 'MySQL 8.0.30+'; } else { $databaseName = "MySQL {$compareSQLVersion}"; $expectedVersion = $databaseName = "MariaDB {$compareSQLVersion}"; $expectedVersion = '8.0.30'; - $alternativeDatabase = 'MariaDB 10.5.12+'; + $alternativeDatabase = 'MariaDB 10.5.15+'; } $result = (\version_compare( diff --git a/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php b/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php index 6a21ce9cbb..19278c61bd 100644 --- a/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php +++ b/wcfsetup/install/files/lib/acp/page/SystemCheckPage.class.php @@ -57,7 +57,7 @@ class SystemCheckPage extends AbstractPage '8' => '8.0.30', ], 'mariadb' => [ - '10' => '10.5.12', + '10' => '10.5.15', ], ]; diff --git a/wcfsetup/install/files/lib/system/WCFSetup.class.php b/wcfsetup/install/files/lib/system/WCFSetup.class.php index b020b0ac32..0a23948dff 100644 --- a/wcfsetup/install/files/lib/system/WCFSetup.class.php +++ b/wcfsetup/install/files/lib/system/WCFSetup.class.php @@ -537,8 +537,8 @@ final class WCFSetup extends WCF $sqlVersion = $db->getVersion(); $compareSQLVersion = \preg_replace('/^(\d+\.\d+\.\d+).*$/', '\\1', $sqlVersion); if (\stripos($sqlVersion, 'MariaDB')) { - if (!(\version_compare($compareSQLVersion, '10.5.12') >= 0)) { - throw new SystemException("Insufficient MariaDB version '" . $compareSQLVersion . "'. Version '10.5.12' or greater is needed."); + if (!(\version_compare($compareSQLVersion, '10.5.15') >= 0)) { + throw new SystemException("Insufficient MariaDB version '" . $compareSQLVersion . "'. Version '10.5.15' or greater is needed."); } } else { if (!(\version_compare($compareSQLVersion, '8.0.30') >= 0)) { diff --git a/wcfsetup/test.php b/wcfsetup/test.php index 9b9b01cf6f..a9277de7d8 100644 --- a/wcfsetup/test.php +++ b/wcfsetup/test.php @@ -79,8 +79,8 @@ $phrases = [ 'en' => 'MySQL Requirements', ], 'mysql_version' => [ - 'de' => 'Bitte stellen Sie sicher, dass MySQL 8.0.30+ oder MariaDB 10.5.12+ mit InnoDB-Unterstützung vorhanden ist.', - 'en' => 'Please make sure that MySQL 8.0.30+ or MariaDB 10.5.12+, with InnoDB support is available.', + 'de' => 'Bitte stellen Sie sicher, dass MySQL 8.0.30+ oder MariaDB 10.5.15+ mit InnoDB-Unterstützung vorhanden ist.', + 'en' => 'Please make sure that MySQL 8.0.30+ or MariaDB 10.5.15+, with InnoDB support is available.', ], 'result' => [ 'de' => 'Ergebnis', -- 2.20.1