Regular token value moved to Field Default Token's field. Also unable to uninstall module.

Created on 22 July 2019, almost 5 years ago
Updated 31 August 2023, 10 months ago

Hello! I tested this module and it partially works but has some odd behaviors in few situations. For example used with modules like Views Field View β†’ or Viewfield β†’ it behaves strangely and if I populate regular token field with view and pass argument as token, this token from argument is replaced with number 1 and token is saved to Field Default Token's field as shown on image.

Also another problem that is major is if I uninstall this module there is no more token field anywhere and I am getting these notices:

Warning: call_user_func() expects parameter 1 to be a valid callback, function 'field_default_token_default_value_callback' not found or invalid function name in Drupal\Core\Field\FieldConfigBase->getDefaultValue() (line 397 of core/lib/Drupal/Core/Field/FieldConfigBase.php).
Drupal\Core\Field\FieldConfigBase->getDefaultValue(Object) (Line: 169)
Drupal\Core\Field\FieldItemList->applyDefaultValue() (Line: 188)
Drupal\Core\Entity\ContentEntityStorageBase->initFieldValues(Object, Array) (Line: 130)
Drupal\Core\Entity\ContentEntityStorageBase->doCreate(Array) (Line: 221)
Drupal\Core\Entity\EntityStorageBase->create(Array) (Line: 286)
_field_create_entity_from_ids(Object) (Line: 110)
Drupal\field_ui\Form\FieldConfigEditForm->form(Array, Object) (Line: 117)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 519)
Drupal\Core\Form\FormBuilder->retrieveForm('field_config_edit_form', Object) (Line: 276)
Drupal\Core\Form\FormBuilder->buildForm('field_config_edit_form', Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 44)
Drupal\bat_api\StackMiddleware\BatApiMiddleware->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 44)
Drupal\services\StackMiddleware\FormatSetter->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Warning: call_user_func() expects parameter 1 to be a valid callback, function 'field_default_token_default_value_callback' not found or invalid function name in Drupal\Core\Field\FieldConfigBase->getDefaultValue() (line 397 of core/lib/Drupal/Core/Field/FieldConfigBase.php).
Drupal\Core\Field\FieldConfigBase->getDefaultValue(Object) (Line: 169)
Drupal\Core\Field\FieldItemList->applyDefaultValue() (Line: 188)
Drupal\Core\Entity\ContentEntityStorageBase->initFieldValues(Object, Array) (Line: 130)
Drupal\Core\Entity\ContentEntityStorageBase->doCreate(Array) (Line: 221)
Drupal\Core\Entity\EntityStorageBase->create(Array) (Line: 286)
_field_create_entity_from_ids(Object) (Line: 110)
Drupal\field_ui\Form\FieldConfigEditForm->form(Array, Object) (Line: 117)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 519)
Drupal\Core\Form\FormBuilder->retrieveForm('field_config_edit_form', Object) (Line: 276)
Drupal\Core\Form\FormBuilder->buildForm('field_config_edit_form', Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 44)
Drupal\bat_api\StackMiddleware\BatApiMiddleware->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 44)
Drupal\services\StackMiddleware\FormatSetter->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Warning: call_user_func() expects parameter 1 to be a valid callback, function 'field_default_token_default_value_callback' not found or invalid function name in Drupal\Core\Field\FieldConfigBase->getDefaultValue() (line 397 of core/lib/Drupal/Core/Field/FieldConfigBase.php).
Drupal\Core\Field\FieldConfigBase->getDefaultValue(Object) (Line: 169)
Drupal\Core\Field\FieldItemList->applyDefaultValue() (Line: 188)
Drupal\Core\Entity\ContentEntityStorageBase->initFieldValues(Object, Array) (Line: 130)
Drupal\Core\Entity\ContentEntityStorageBase->doCreate(Array) (Line: 221)
Drupal\Core\Entity\EntityStorageBase->create(Array) (Line: 286)
_field_create_entity_from_ids(Object) (Line: 110)
Drupal\field_ui\Form\FieldConfigEditForm->form(Array, Object) (Line: 117)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 519)
Drupal\Core\Form\FormBuilder->retrieveForm('field_config_edit_form', Object) (Line: 276)
Drupal\Core\Form\FormBuilder->buildForm('field_config_edit_form', Object) (Line: 93)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 582)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 151)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 68)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 44)
Drupal\bat_api\StackMiddleware\BatApiMiddleware->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 44)
Drupal\services\StackMiddleware\FormatSetter->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 693)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

πŸ› Bug report
Status

Active

Version

1.0

Component

Code

Created by

πŸ‡·πŸ‡ΈSerbia miksha

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.

  • πŸ‡©πŸ‡ͺGermany diqidoq Berlin | Hamburg | New York | London | Paris

    This uninstall issue (also mentioned elsewhere) is Critical and should get some attention of module maintainers since this project used to be a sidecar project for a Drupal core planned feature and probably a lot of users cannot uninstall it yet this reasons and cannot update to Drupal 10.

  • πŸ‡©πŸ‡ͺGermany diqidoq Berlin | Hamburg | New York | London | Paris
Production build 0.69.0 2024