Problem/Motivation
Enabling the LottieFiles Field module causes a temporary unavailable error while creating a new field on any content type through UI admin/structure/types/manage/project/fields/add-field.
TypeError: Cannot access offset of type Drupal\Core\StringTranslation\TranslatableMarkup in isset or empty in Drupal\Core\Plugin\DefaultPluginManager->doGetDefinition() (line 45 of core/lib/Drupal/Component/Plugin/Discovery/DiscoveryTrait.php).
This error seems highly related to the discussion in this issue: https://www.drupal.org/project/drupal/issues/3475505
Steps to reproduce
1. Install Drupal 11.1.5 through composer
2. Try to create a new field on any content type
Proposed resolution
API has been changed for new field type categories based on documentation
https://www.drupal.org/node/3375748
Remaining tasks
Full Stack trace
TypeError: Cannot access offset of type Drupal\Core\StringTranslation\TranslatableMarkup in isset or empty in Drupal\Core\Plugin\DefaultPluginManager->doGetDefinition() (line 45 of core/lib/Drupal/Component/Plugin/Discovery/DiscoveryTrait.php).
Drupal\Core\Plugin\DefaultPluginManager->getDefinition() (Line: 16)
Drupal\Core\Plugin\Factory\ContainerFactory->createInstance() (Line: 76)
Drupal\Component\Plugin\PluginManagerBase->createInstance() (Line: 136)
Drupal\field_ui\Form\FieldStorageAddForm->processFieldDefinitions() (Line: 80)
Drupal\field_ui\Form\FieldStorageAddForm->buildForm()
call_user_func_array() (Line: 528)
Drupal\Core\Form\FormBuilder->retrieveForm() (Line: 279)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 73)
Drupal\Core\Controller\FormController->getContentResult()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 593)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 183)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 53)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 709)
Drupal\Core\DrupalKernel->handle() (Line: 19)
User interface changes
API changes
https://www.drupal.org/node/3375748
Data model changes
| Comment | File | Size | Author |
|---|
Issue fork acquia_dam-3534537
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
Comment #4
vipin.mittal18The issue can be reproduced by enabling the LottieFiles Field module and navigating to the page

admin/structure/types/manage/project/fields/add-field. Refer below screenshot:
Comment #5
vishalkhode commentedThe WSOD error is caused by the LottieFiles Field module, not due the Acquia DAM module. The
acquia_dam_assetfield type hasno_ui = TRUE, meaning it cannot be created through the UI. Therefore, it is unlikely for this error to occur when creating new field via the UI.Comment #6
japerryAgreed, I doubt this will throw a WSOD, however, we should add the BC shim or remove the category altogether
Comment #7
vishalkhode commented@japerry I think removing category make more sense here because as per the Drupal, the category can be defined to ensure that the field is appropriately listed under the specified category when created via the UI. However, since our field is configured not to display in the UI, so we can safely remove this option.
Comment #8
rajeshreeputrarequesting review.
Comment #9
vishalkhode commentedReviewed changes, looks good to me. Hence, RTBC.
Comment #11
japerryAgreed, with no ui this shouldn't appear at all anyway.