facets_facet entity type does not exist

Created on 28 January 2021, about 4 years ago
Updated 11 March 2025, about 1 month ago

Problem/Motivation

A WSOD after a site install with drush. See : https://www.drupal.org/project/droopler/issues/3193777 for the error.

Steps to reproduce

  1. Get a drupal project up and running
  2. Require facets (with composer)
  3. Enable facets with drush
  4. Perform a site install with : drush si --existing-config
  5. See the error, or log in as admin and see the error (depends on the error logging level)

Proposed resolution

in facets.install in a update or install hook:

  $entity_type_manager = \Drupal::entityTypeManager();
  $entity_type_manager->clearCachedDefinitions();
  $entity_type = $entity_type_manager->getDefinition('facets_facet');
  \Drupal::entityDefinitionUpdateManager()->installEntityType($entity_type);

Remaining tasks

Review

User interface changes

None

API changes

None

Data model changes

None

🐛 Bug report
Status

Postponed: needs info

Version

1.6

Component

Code

Created by

🇳🇱Netherlands tomvanetten

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇧🇪Belgium borisson_ Mechelen, 🇧🇪

    To me, this looks like an issue in drupal's installer process? Does this still happen? If it does we need to look at the dependencies of our own schema.

Production build 0.71.5 2024