Output buffering status check fails when run via CLI

Created on 3 January 2024, 5 months ago
Updated 18 January 2024, 5 months ago

Problem/Motivation

A status check was added in πŸ› Post-response task running (destructable services) are actually blocking; add test coverage and warn for common misconfiguration Fixed to validate that output buffering is enabled. Related change record β†’ .

  if ($phase === 'runtime') {
    if (!function_exists('fastcgi_finish_request') && !function_exists('litespeed_finish_request') && !ob_get_status()) {
      $requirements['output_buffering'] = [
        'title' => t('Output Buffering'),
        'error_value' => t('Not enabled'),
        'severity' => REQUIREMENT_WARNING,
        'description' => t('<a href="https://www.php.net/manual/en/function.ob-start.php">Output buffering</a> is not enabled. This may degrade Drupal\'s performance. You can enable output buffering by default <a href="https://www.php.net/manual/en/outcontrol.configuration.php#ini.output-buffering">in your PHP settings</a>.'),
      ];
    }
  }

Even when output buffering is enabled, this check fails when run via the command line.

Steps to reproduce

  1. Ensure the output buffering is enabled and not showing a warning at /admin/reports/status.
  2. Run drush status-report. Output buffering warning will be present.

Proposed resolution

Add a check, similar to what is done for APCu, to ensure it is not being run from the command line.

πŸ› Bug report
Status

Fixed

Version

10.2 ✨

Component
SystemΒ  β†’

Last updated 2 days ago

No maintainer
Created by

πŸ‡ΊπŸ‡ΈUnited States markdorison

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

Merge Requests

Comments & Activities

Production build 0.69.0 2024