I did a core update from drupal 8.27 to 8.3.2 i am getting error

Drupal\Component\Plugin\Exception\PluginNotFoundException: The "integer" plugin does not exist. in Drupal\Core\Plugin\DefaultPluginManager->doGetDefinition()

What might be causing it and how can i get rid of this error.

Comments

adityaj created an issue. See original summary.

yash_khandelwal’s picture

Priority: Normal » Major
cilefen’s picture

@adityaj We need a little more information. Did /update.php proceed without errors? What action is taken that triggers the error?

aaronbauman’s picture

"drush up" from Drupal 8.2.7 to 8.3.5 exhibited this error.

many of the update procedures ran smoothly, but drupal is choking with the following updates pending:

system module :
Update entity displays to contain the region for each field.
Force caches using hashes to be cleared (Twig, render cache, etc.).
Force plugin definitions to be cleared. @see https:www.drupal.orgnode2802663

user module :
Enforce order of role permissions.

views module :
Rebuild caches to ensure schema changes are read in.

I've run updb 3 times.

The full error message is:

Failed: Drupal\Component\Plugin\Exception\PluginNotFoundException: The "integer" plugin does not exist. in [error]
Drupal\Core\Plugin\DefaultPluginManager->doGetDefinition() (line 52 of
~/core/lib/Drupal/Component/Plugin/Discovery/DiscoveryTrait.php).

adityaj’s picture

@cilefen steps to recreate error "integer plugin not found" in step #3

adityaj’s picture

Priority: Major » Critical
adityaj’s picture

nicrodgers’s picture

For those who are getting this after running drush updb, have you also ran drush entup? If not, try running drush entup and then drush updb again.

adityaj’s picture

@nicrodgers

I did try entup too and then drush updb and getting same error

adityaj’s picture

When i do a fresh install of drupal 8.27 and update to 8.35 i don't get any error. Above error is in existing site which is already configured and have multiple contributed module installed

cilefen’s picture

xjm’s picture

It's really hard to diagnose errors like this without more specific steps to reproduce the problem. Try documenting things like your installed contributed modules, database, PHP version, etc. so that you and others encountering the error can see if there's a common thread.

xjm’s picture

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.6 was released on August 2, 2017 and is the final full bugfix release for the Drupal 8.3.x series. Drupal 8.3.x will not receive any further development aside from critical and security fixes. Sites should prepare to update to 8.4.0 on October 4, 2017. (Drupal 8.4.0-alpha1 is available for testing.)

Bug reports should be targeted against the 8.4.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.5.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

adityaj’s picture

Work around suggested by incrn8(comment #6) on https://www.drupal.org/node/2783367 works fine for me.

voleger’s picture

voleger’s picture

As an option just try to add this code in enabled custom module in your project.

/**
 * Implements hook_entity_base_field_info_alter().
 *
 * @see hook_entity_base_field_info_alter()
 * @see https://www.drupal.org/node/2346329
 */
function menu_item_extras_entity_base_field_info_alter(&$fields, EntityTypeInterface $entity_type) {
  /** @var \Drupal\Core\Field\BaseFieldDefinition[] $fields */
  if ($entity_type->id() === 'menu_link_content' && isset($fields['weight'])) {
    $options = $fields["weight"]->getDisplayOptions('view');
    // Lets check if field definition is buggy.
    if ($options['type'] === 'integer') {
      $options['type'] = 'number_integer';
      // @TODO: This should be fixed in the menu_link_content core module.
      // @see https://www.drupal.org/node/2903161
      $fields['weight']->setDisplayOptions('view', $options);
    }
  }
}

If it does not help, check out may be some other display options in other modules that use incorrect plugin id.

andypost’s picture

Status: Postponed (maintainer needs more info) » Closed (duplicate)

the related fixed in 8.4 #2903161: Fix incorrect FieldFormatter id for "weight" field in base field definition in display options

feel free to reopen if possible to reproduce