Query condition 'node.uuid IN ()' cannot be empty

Created on 31 May 2024, 7 months ago
Updated 1 June 2024, 7 months ago

Problem/Motivation

When I want to import any model I am getting following error (I have tried on clean install of Drupal also) :

The website encountered an unexpected error. Try again later.

Drupal\Core\Database\InvalidQueryException: Query condition 'node.uuid IN ()' cannot be empty. in Drupal\Core\Database\Query\Condition->condition() (line 106 of core\lib\Drupal\Core\Database\Query\Condition.php).
Drupal\Core\Database\Query\Select->condition('node.uuid', Array, 'IN') (Line: 77)
Drupal\Core\Entity\Query\Sql\Condition->compile(Object) (Line: 176)
Drupal\Core\Entity\Query\Sql\Query->compile() (Line: 81)
Drupal\Core\Entity\Query\Sql\Query->execute() (Line: 607)
Drupal\Core\Entity\EntityStorageBase->loadByProperties(Array) (Line: 63)
Drupal\Core\Entity\EntityRepository->loadEntityByUuid('node', NULL) (Line: 500)
Drupal\Core\Config\ConfigManager->findMissingContentDependencies() (Line: 693)
Drupal\Core\Config\ConfigImporter->processMissingContent(Array) (Line: 561)
Drupal\Core\Config\ConfigImporter->doSyncStep('processMissingContent', Array) (Line: 537)
Drupal\Core\Config\ConfigImporter->import() (Line: 365)
Drupal\eca_ui\Form\Import->submitForm(Array, Object)
call_user_func_array(Array, Array) (Line: 129)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 67)
Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 597)
Drupal\Core\Form\FormBuilder->processForm('eca_import', Array, Object) (Line: 325)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 627)
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: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->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: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

It does not matter which model you want to import - this issue occurs for any. I have tried to download from https://ecaguide.org/library/simple/combined_conditions/ or create my and export > Import. Still the same.

Does anyone else experience the same issue ?

πŸ› Bug report
Status

Active

Version

3.0

Component

Code

Created by

πŸ‡ΈπŸ‡°Slovakia coaston

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @coaston
  • πŸ‡ΈπŸ‡°Slovakia coaston

    + when I go back in browser and refresh I can see following to warnings :

    Warning: Undefined array key 1 in Drupal\Core\Config\ConfigManager->findMissingContentDependencies() (line 499 of core\lib\Drupal\Core\Config\ConfigManager.php).
    Drupal\Core\Config\ConfigManager->findMissingContentDependencies() (Line: 693)
    Drupal\Core\Config\ConfigImporter->processMissingContent(Array) (Line: 561)
    Drupal\Core\Config\ConfigImporter->doSyncStep('processMissingContent', Array) (Line: 537)
    Drupal\Core\Config\ConfigImporter->import() (Line: 365)
    Drupal\eca_ui\Form\Import->submitForm(Array, Object)
    call_user_func_array(Array, Array) (Line: 129)
    Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 67)
    Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 597)
    Drupal\Core\Form\FormBuilder->processForm('eca_import', Array, Object) (Line: 325)
    Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
    Drupal\Core\Controller\FormController->getContentResult(Object, Object)
    call_user_func_array(Array, Array) (Line: 123)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 627)
    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: 181)
    Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
    Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
    Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
    Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
    Drupal\big_pipe\StackMiddleware\ContentLength->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: 48)
    Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
    Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
    Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
    
    

    and

    Warning: Undefined array key 2 in Drupal\Core\Config\ConfigManager->findMissingContentDependencies() (line 499 of core\lib\Drupal\Core\Config\ConfigManager.php).
    Drupal\Core\Config\ConfigManager->findMissingContentDependencies() (Line: 693)
    Drupal\Core\Config\ConfigImporter->processMissingContent(Array) (Line: 561)
    Drupal\Core\Config\ConfigImporter->doSyncStep('processMissingContent', Array) (Line: 537)
    Drupal\Core\Config\ConfigImporter->import() (Line: 365)
    Drupal\eca_ui\Form\Import->submitForm(Array, Object)
    call_user_func_array(Array, Array) (Line: 129)
    Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 67)
    Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 597)
    Drupal\Core\Form\FormBuilder->processForm('eca_import', Array, Object) (Line: 325)
    Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
    Drupal\Core\Controller\FormController->getContentResult(Object, Object)
    call_user_func_array(Array, Array) (Line: 123)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 627)
    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: 181)
    Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
    Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
    Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
    Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
    Drupal\big_pipe\StackMiddleware\ContentLength->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: 48)
    Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
    Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
    Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
    
  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    I haven't seen that before and can't reproduce.

    Can you reproduce that on a fresh installation of Drupal? If so, can you please provide the exact steps (including versions of installed components) on how we could reproduce that?

  • πŸ‡ΈπŸ‡°Slovakia coaston

    I just tried with clean and I found out it is caused by this module easy_entity_field β†’

    1.Install easy_entity_field
    2.Configure > Enable Content
    3.Add any base field (no need to create any content(
    4. Try import of any ECA module.

    I do have 2 base fields so probably this is the reason why I can see 2 warnings.
    When I deleted them - it works as expected. However I cannot remove them on my prod because they are being used.

    Can I do import from my test to prod even there are such errors ? ( I believe model should not be impacted).

    However it seems this easy_entity_field module is not compatible with ECA or not sure why there is problem with ECA... But easy_entity_field is awesome module...

  • πŸ‡©πŸ‡ͺGermany jurgenhaas Gottmadingen

    Thanks for the details. With that, I was able to find out, this is an error in the easy_entity_field. Here is what happens:

    In \Drupal\Core\Config\ConfigManager::findMissingContentDependencies, Drupal core tries to find content dependencies when importing config. The base field config entity from the easy_entity_field comes with a content dependency on node. And that leads to the error then because content dependencies need to be in the format entity_type:bundle:uuid as documented in that method.

Production build 0.71.5 2024