Verified Commit b4b19a78 authored by Alex Pott's avatar Alex Pott
Browse files

Issue #3400302 by poker10, longwave, nterbogt: PHP OPcache bug detection issue

(cherry picked from commit 6dfc9250)
parent 32faa02a
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -338,7 +338,7 @@ function system_requirements($phase) {
    // errors, so warn about that when running Drupal on those versions.
    // @todo Remove this when \Drupal::MINIMUM_PHP is at least 8.1.6 in
    //   https://www.drupal.org/i/3305726.
    if (version_compare(\Drupal::MINIMUM_PHP, '8.1.6') < 0) {
    if (version_compare($phpversion, '8.1.6') < 0) {
      $requirements['php']['description'] = t('PHP %version has <a href=":bug_url">an OPcache bug that can cause fatal errors with class autoloading</a>. This can be fixed by upgrading to PHP 8.1.6 or later. See <a href="http://php.net/supported-versions.php">PHP\'s version support documentation</a> and the <a href=":php_requirements">Drupal PHP requirements</a> page for more information.', [
        '%version' => $phpversion,
        ':bug_url' => 'https://github.com/php/php-src/issues/8164',
+1 −1
Original line number Diff line number Diff line
@@ -76,7 +76,7 @@ public function testStatusPage() {
      // bug in OPcache.
      // @todo Remove this when \Drupal::MINIMUM_PHP is at least 8.1.6 in
      //   https://www.drupal.org/i/3305726.
      if (version_compare(\Drupal::MINIMUM_PHP, '8.1.6') < 0) {
      if (version_compare($phpversion, '8.1.6') < 0) {
        $this->assertSession()->pageTextContains("PHP $phpversion has an OPcache bug that can cause fatal errors with class autoloading. This can be fixed by upgrading to PHP 8.1.6 or later.");
        $this->assertSession()->linkExists('an OPcache bug that can cause fatal errors with class autoloading');
      }