Warning: reset() expects parameter 1 to be array, boolean given in ds_search_search_page() (line 272 of /Users/nickveenhof/Sites/dev/apachesolrissues/site/sites/all/modules/contrib/ds/modules/ds_search/ds_search.module).
Warning: reset() expects parameter 1 to be array, boolean given in ds_search_search_page() (line 272 of /Users/nickveenhof/Sites/dev/apachesolrissues/site/sites/all/modules/contrib/ds/modules/ds_search/ds_search.module).
Strict warning: Creating default object from empty value in ds_search_search_page() (line 353 of /Users/nickveenhof/Sites/dev/apachesolrissues/site/sites/all/modules/contrib/ds/modules/ds_search/ds_search.module).
Strict warning: Creating default object from empty value in ds_search_search_page() (line 353 of /Users/nickveenhof/Sites/dev/apachesolrissues/site/sites/all/modules/contrib/ds/modules/ds_search/ds_search.module).

I haven't delved in depth in to what the problem could be but the code is the following

// odd because I don't think this hook should even execute?
ds_search_search_page()
$data = ds_entity_view_fallback($entity_type, array($result->entity_id => $result), variable_get('ds_search_view_mode', 'search_result'));
$data = reset($data);

Comments

swentel’s picture

Oh, I thought this was aiming at a solr release, not the drupal module ... oh dear. Anyway, did a quick test on latest HEAD both modules (running solr 1.4.1 though, but not sure if that makes any difference?) and can't reproduce this for now.

zebrax’s picture

I am getting the same error. It looks like the error is due to a file entity in the results set. I am using apachesolr_attachments module.

WoozyDuck’s picture

Priority: Normal » Major

I also have this problem, show results don't show up.
Using Display Suite 7.x-2.2 / Solr framework 7.x-1.2 / Solr attachment 7.x-1.2

swentel’s picture

Status: Active » Closed (duplicate)

I'm going to remove the whole json encode and decode stuff and totally rewrite this part, see #1950660: DS turning objects into arrays by mistake as well as generating a lot of warnings