cancel
Showing results for 
Search instead for 
Did you mean: 

Elasticsearch7 returns string but not array for the category page.

Elasticsearch7 returns string but not array for the category page.

When I tried to load my category page, the following error showing..

TypeError: Return value of Magento\Elasticsearch7\Model\Client\Elasticsearch::query() must be of the type array, string returned /hostname.local/app/code/Magento/Elasticsearch7/Model/Client/Elasticsearch.php:367

Versions details

  • Mac OS Big sure 11.2.x
  • MAMP Pro 6.3.1
  • Magento 2.4.2
  • Elasticsearch 7.12.0 (installed recently using Homebrew)

This issue is reported here before but there is no help at all.

I updated the Store->Configuration -> Catalog -> Catalog -> catalogSearch area in admin and the Test button returns Successfull.

Any kind of help will be appreciated..
Error page screengrab:
screencapture-carb2-local-index-php-supplied-html-2021-04-04-19_06_48.png

2 REPLIES 2

Re: Elasticsearch7 returns string but not array for the category page.

@sohaibgondal Did you get the solution? I am facing the same issue.

Re: Elasticsearch7 returns string but not array for the category page.

We appreciate it. If a business wants to know how many boxes of widgets they have left, they can contact Andersen and the company will develop logistics software for small business. Logistics software for small business helps business owners keep track of their inventory, shipping, and delivery. Logistics software for small business stimulates them make better decisions about where to allocate their resources and how to optimize their delivery routes.