Problem/Motivation

This error started happening after upgrade to Drupal 11 and PHP 8.3.

Steps to reproduce

Adding a field to Example media entity via https://example.ddev.site/admin/structure/paragraphs_type/example_media/... , I'm getting this error:

The website encountered an unexpected error. Try again later.

AssertionError: "Give" must be defined in MODULE_NAME.field_type_categories.yml in assert() (line 183 of core/lib/Drupal/Core/Field/FieldTypePluginManager.php).

Drupal\Core\Field\FieldTypePluginManager->getGroupedDefinitions() (Line: 131)
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: 124)
Drupal\cloudflare\CloudFlareMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 709)
Drupal\Core\DrupalKernel->handle() (Line: 19)

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Comments

mlncn created an issue. See original summary.

mlncn credited onion.

  • mlncn committed 51381d03 on 2.0.x
    Issue #3527228 by mlncn, onion: Error on ANY new field creation: "Give"...
mlncn’s picture

Status: Active » Needs review
matslats’s picture

I'm not set up for working on d11 yet, but if you want to create the file here's what I think it should contain.

give_method:
  label: 'Give payment method'
  description: 'Enumerated fields extensible with a hook.'
  weight: 5
  

mlncn’s picture

That last commit had a merge/rebase problem:

ParseError: syntax error, unexpected token "<<", expecting ")" in web/modules/contrib/give/src/Plugin/Field/FieldType/PaymentMethod.php).

matslats’s picture

sorry it looks like somebody committed a fix before me.
i fixed and pushed again.

mlncn’s picture

Status: Needs review » Fixed

Now that this issue is closed, please review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, please credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.