When trying to upgrade to Search API 1.33, the Solr Document Datasource has issues:
Drupal\Component\Plugin\Exception\PluginNotFoundException while adding Views handlers for field Solr Document » FIELD_NAME on index INDEX: The "text" plugin does not exist. Valid plugin IDs for Drupal\Core\TypedData\TypedDataManager are: …

It seems that issue is caused by the change in _search_api_views_get_handlers().
The exceptions are triggered by the new call is_a($definition?->getClass(), EntityReferenceItem::class, TRUE) .
It seems that check is too early. Obviously some custom field types come first and cause such exceptions because the fallback types text, date , … aren’t loaded yet.

Issue fork search_api-3438940

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

mkalkbrenner created an issue. See original summary.

mkalkbrenner’s picture

Status: Active » Needs review
StatusFileSize
new1.13 KB

The issue is caused by #3394367: Not all fields that have a target_type setting are entity references.
That patch tries to avoid a Drupal\Component\Plugin\Exception\PluginNotFoundException.

But the new $definition->getClass() that has been added before the critical section could lead to a Drupal\Component\Plugin\Exception\PluginNotFoundException itself!

mkalkbrenner’s picture

Title: Search API 1.33 breaks Search API Solr Datasources » Search API 1.33 breaks Search API Solr Datasources and installations with custom field types that uses fallback types
Issue summary: View changes
mkalkbrenner’s picture

StatusFileSize
new297.4 KB
mkalkbrenner’s picture

Title: Search API 1.33 breaks Search API Solr Datasources and installations with custom field types that uses fallback types » Search API 1.33 breaks Search API Solr Datasources and installations with custom field types that use fallback types
Issue summary: View changes

drunken monkey made their first commit to this issue’s fork.

drunken monkey’s picture

Issue summary: View changes
Status: Needs review » Active

Created an MR with your patch and some minor style changes. (Testing of patches is not working anymore, we now need to use MRs – a bit funny, I know.) Would be great to get some quick feedback on whether this still worked for you, then I’ll merge and create release 1.34 – hopefully without any critical bugs this time.

And then we’ll either keep this open or create a follow-up to develop a proper fix.

drunken monkey’s picture

Priority: Critical » Normal
Status: Active » Fixed

As discussed on Slack this seems to not be a bug in this module after all, but one in the Solr module that was simply uncovered by the recent change in this one. I created a follow-up issue #3439023: Invalid types "text" and "date" specified in SolrFieldDefinition data defintions in the Solr module but will still create a new release of this module with the workaround in the MR to keep more people from being affected.

So, merged. Thanks again!

Status: Fixed » Closed (fixed)

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