-
Notifications
You must be signed in to change notification settings - Fork 23
Event type machine names exceed the 32 character limit imposed by entity reference #143
Comments
See failing test in PR #144 `
` |
I'm not sure what to propose here since RNG depends on Core's entity_reference and Dynamic Entity Reference contrib module, both of which impose the 32-character db column length limit. Flag module, having no external dependencies like this, was able to handle the same exact issue -- lengths of db columns for entity and bundle names are too short. In fact, there are several different situations in Core and contrib where this limitation has been dealt with -- see https://www.drupal.org/node/1709960. |
My solution is going to be to make sure the combination of my 'entity_type.entity_bundle' does not exceed 32 characters. :/ |
Not sure how to handle this best yet -- I would like to move the issue queue back to Drupal.org, rather than having fragmented issue queues across different accounts... |
Currently, when creating an event type based on a Commerce Product type I have, I end up with a Event type machine name of 42 characters.
This is because RNG creates a two-part ID for event types in the format "{entity_type}.{bundle}".
But the 'entity_reference' field schema limits the 'type' field of RNG's Registration entity to 32 characters, producing a fatal error
Drupal\Core\Entity\EntityStorageException: SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'type' at row 1: INSERT INTO {registration} (vid, type, uuid, langco ...
Also, Dynamic Entity Reference also imposes the same 32-character limit on the Registration 'event' field.
Looks like we need to limit the machine name of registration types to 32 characters. :/
The text was updated successfully, but these errors were encountered: