solr-power icon indicating copy to clipboard operation
solr-power copied to clipboard

Deprecation notice in php8.1

Open benerd opened this issue 1 year ago • 4 comments

Hi,

I am getting deprecation notices after updating to php8.1

http_build_query(): Passing null to parameter #2 ($numeric_prefix) of type string is deprecated location-> wp-content/plugins/solr-power/vendor/solarium/solarium/src/Component/RequestBuilder/RequestParamsTrait.php:153

and

Exception::__construct(): Passing null to parameter #2 ($code) of type int is deprecated location -> wp-content/plugins/solr-power/vendor/solarium/solarium/src/Exception/HttpException.php:63

which is coming from solarium plugin, could you please update the solarium composer package to resolve this.

Thanks :)

benerd avatar Jul 31 '23 05:07 benerd

In case the research of Solarium's support helps @pwtyler decide how to tackle this:

I'm hoping that since Terminus requires 7.4 or greater and Pantheon's the core guide recommends at least 8.0, cutting a major release to 3.0.0 that drops support for <7.3 would be considered.

ecaron avatar Sep 08 '23 04:09 ecaron

@pwtyler do you have an update here? Pantheon now starts at PHP 8.2 by default?

junaidbhura avatar Aug 02 '24 01:08 junaidbhura

@junaidbhura Hi! We don't have an update on this currently. If you're using the Solr Power plugin with your WordPress site, we recommend sticking with PHP 8.1 for now.

scottbuscemi avatar Aug 02 '24 19:08 scottbuscemi

@scottbuscemi This happens with PHP 8.1 as well! The deprecation notice was added starting 8.1.

Since PHP 8.0 has now reached end of life, this should be picked up as soon as possible! https://www.php.net/supported-versions.php

Surely you wouldn't suggest downgrading to 8.0?

junaidbhura avatar Aug 04 '24 23:08 junaidbhura