Problem/Motivation
On installing the module for the first time (via drush) I get errors about missing revision keys, for example:
"The entity type bookable_calendar does not have an "revision_created" entity revision metadata key.
"The entity type bookable_calendar does not have an "revision_user" entity revision metadata key.
Also, similar errors for the bookable_calendar_opening entity.
Apparently it stops the module from creating all the tables it's meant to, but not from being installed. Which means that when you try to uninstall the module, you get these errors:
In Connection.php line 805:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'd9_bookable.book
ing' doesn't exist: SELECT "base_table"."id" AS "id", "base_table"."id" AS
"base_table_id"
FROM
{booking} "base_table"
LIMIT 1 OFFSET 0; Array
(
)
In Statement.php line 59:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'd9_bookable.book
ing' doesn't exist
Steps to reproduce
Install the module via composer on a fresh install of Drupal 9, and then enable it via drush.
Proposed resolution
Add the cited key to the annotation for the BookableCalendar entity class.
Comment | File | Size | Author |
---|---|---|---|
#3 | bookable_calendar-install-errors-3175171-3.patch | 1008 bytes | mandclu |
Comments
Comment #2
mandclu CreditAttribution: mandclu at Northern Commerce commentedUpdate: adding the cited annotation key results in a second error:
The entity type bookable_calendar does not have an "revision_user" entity revision metadata key.
Comment #3
mandclu CreditAttribution: mandclu at Northern Commerce commentedHere's a patch that resolves the errors for me. Should have mentioned that I'm testing with Drupal 9.0.6.
Comment #5
josh.fabeanThanks, got that patched. I'm on Drupal 8.9 and those were generated by a mix of Drush generate and Drupal Code Generator, so I wonder which one messed that up.
Comment #6
josh.fabeanComment #7
josh.fabeanTested again on a fresh d9 site, seems fixed. Thanks!
Comment #8
josh.fabean