Upgrade from 22.0 to 22.3 breaks Solr search and requests return 500 errors.

  • markk
    Participant
    2 years, 1 month ago #30772

    Also breaking in v22.2.
    PHP 7.4.26 with Apache Webserver
    Wordpress 6.0.1

    Error Details

    =============
    An error of type E_ERROR was caused in line 286 of the file /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/core/vendor/solarium/solarium/src/Core/Client/Client.php. Error message: Uncaught TypeError: Argument 2 passed to Solarium\Core\Client\Client::__construct() must be an instance of Psr\EventDispatcher\EventDispatcherInterface, instance of Symfony\Component\EventDispatcher\EventDispatcher given, called in /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/core/classes/engines/solarium/class-wpsolr-solariumclient.php on line 65 and defined in /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/core/vendor/solarium/solarium/src/Core/Client/Client.php:286
    Stack trace:
    #0 /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/core/classes/engines/solarium/class-wpsolr-solariumclient.php(65): Solarium\Core\Client\Client->__construct(Object(Solarium\Core\Client\Adapter\Http), Object(Symfony\Component\EventDispatcher\EventDispatcher), Array)
    #1 /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/core/classes/engines/class-wpsolr-abstractindexclient.php(240): wpsolr\core\classes\engines\solarium\WPSOLR_IndexSolariumClient->create_search_engine_client(Array)
    #2 /var/www/html/web/app/plugins/wpsolr-pro/wpsolr/
    wpsolr
    Keymaster
    2 years, 1 month ago #30773

    It looks like a conflict with the EventDispatcher library, as mentioned at https://stackoverflow.com/questions/67913020/typeerror-for-argument-2-in-solarium-client

    markk
    Participant
    2 years, 1 month ago #30774

    How can I resolve this? All we did was upgrading the plugin files which worked perfectly fine.

    wpsolr
    Keymaster
    2 years, 1 month ago #30775

    If it is a conflict with Symfony\Component\EventDispatcher\EventDispatcher versions brought by other plugins, you could try to deactivate other plugins and see if the error disappears.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.