- πΊπΈUnited States smustgrave
Since this has been in PNMI for 11 months going to close out for now.
If still a valid bug though please reopen updating the issue summary with steps to trigger this error.
Tried enabling the workflow module but I don't see any issue for what it's worth.
Thanks all!
- π΅π°Pakistan isalmanhaider
Getting the same error
InvalidArgumentException: The state '' does not exist in workflow. in Drupal\workflows\Plugin\WorkflowTypeBase->getState() (line 155 of core/modules/workflows/src/Plugin/WorkflowTypeBase.php).
Steps to reproduce:
under "this workflow applies to" select article, basic page or any content type at /admin/config/workflow/workflows/manage/editorial
then visit node/add/article or node/add/pager you will get WSOD with the following errorDrupal 10.1.4
PHP 8.2.6
content_moderation: 10.1.4
workbench_moderation: 8.x-1.7 - π¨π³China fishfree
It seemd the error occured when an AJAX operation occured.
- πΊπΈUnited States mmenavas
I got the same error message when I was trying to preview a new node that had content moderation enabled. The source of the issue was a bug π Had an issue with preview button Needs work in the workflow_buttons β module.
- Status changed to Needs work
1 day ago 4:10pm 13 August 2025 Reopening this. Ran into this issue on 11.2.2 core. Added repro steps
- First commit to issue fork.
- π―π΅Japan neptune-dc
I can confirm that the updated repro steps result in an error. Thanks a lot.
This is what I got from my test_state:
```
The website encountered an unexpected error. Try again later.InvalidArgumentException: The state 'test_state' does not exist in workflow. in Drupal\workflows\Plugin\WorkflowTypeBase->getState() (line 141 of core/modules/workflows/src/Plugin/WorkflowTypeBase.php).
Drupal\content_moderation\Plugin\WorkflowType\ContentModeration->getState() (Line: 353)
Drupal\diff\DiffEntityComparison->getModerationState() (Line: 286)
Drupal\diff\DiffEntityComparison->getRevisionDescription() (Line: 381)
Drupal\diff\Form\RevisionOverviewForm->buildRevision() (Line: 304)
Drupal\diff\Form\RevisionOverviewForm->buildForm()
call_user_func_array() (Line: 528)
Drupal\Core\Form\FormBuilder->retrieveForm() (Line: 279)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 219)
Drupal\Core\Form\FormBuilder->getForm() (Line: 29)
Drupal\diff\Controller\NodeRevisionController->revisionOverview()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 633)
Drupal\Core\Render\Renderer::Drupal\Core\Render\{closure}()
Fiber->start() (Line: 634)
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: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle() (Line: 116)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 90)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 53)
Drupal\Core\StackMiddleware\AjaxPageState->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 715)
Drupal\Core\DrupalKernel->handle() (Line: 19)
``` - π―π΅Japan neptune-dc
Isn't this a problem for the Diff module though? It seems like the situation is that the diff module isn't handling deleted states correctly.