Fatal error on admin pages with earlier versions of the Solr module

Created on 19 June 2025, about 1 month ago

Problem/Motivation

When using Search API Solr module version 4.2.1 – the latest that supports Drupal 8 – going to /admin/config or /admin/reports/status (or any page that calls search_api_solr_requirements()) will cause a fatal error:

Call to a member function getBody() on array in Drupal\search_api_solr\Utility\Utility::getServerFiles() (line 183 of modules/contrib/search_api_solr/src/Utility/Utility.php)

Steps to reproduce

Install this module on Drupal 8 and visit /admin/reports/status.

Proposed resolution

We probably have to update \Drupal\searchstax\Plugin\SolrConnector\SearchStaxConnector::getFile() to always return a Response object, at least for earlier versions of the Solr module.

🐛 Bug report
Status

Active

Version

1.0

Component

General code

Created by

🇦🇹Austria drunken monkey Vienna, Austria

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

Merge Requests

Comments & Activities

Production build 0.71.5 2024