After upgrading our codebase to 8.0-2.6, we started seeing errors like this:

Notice: Undefined variable: index_config in Drupal\search_api_federated_solr\Form\FederatedSearchPageBlockForm->buildForm() (line 73 of modules/contrib/search_api_federated_solr/src/Form/FederatedSearchPageBlockForm.php).

It seems like https://git.drupalcode.org/project/search_api_federated_solr/commit/792b... might have introduced it?

CommentFileSizeAuthor
#6 3072782-fed-search_bad_var.patch649 bytesagentrickard
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

marcoscano created an issue. See original summary.

agentrickard’s picture

Status: Active » Postponed (maintainer needs more info)

Under what conditions (for example, when browsing to what URL) is this notice shown?

agentrickard’s picture

There is also a known bug that needs review in this release -- #3071462: Bad logic for site list - D8.

marcoscano’s picture

Thanks for the quick feedback!

Another developer reported that, I don't have the details right now, but I can report later if necessary.

In any case, it's an undefined variable php notice, just opening current HEAD with an IDE will indicate the problem on line 73 of \Drupal\search_api_federated_solr\Form\FederatedSearchPageBlockForm. Any code path that exercises that line will throw the warning.

agentrickard’s picture

Status: Postponed (maintainer needs more info) » Active

Thanks!

agentrickard’s picture

Status: Active » Needs review
FileSize
649 bytes

That code looks redundant.

  • agentrickard committed 4806ebc on 8.x-2.x
    Issue #3072782 by agentrickard, marcoscano: PHP notice being thrown...
agentrickard’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.