When attempting to import a view using Configuration Synchronization, the following error occurs:
The configuration cannot be imported because it failed validation for the following reasons:
Configuration block.block.workflowtransitionform depends on the theme that will not be installed after import.

I found that in the database, that the config table block.block.workflowtransitionform setting had an invalid theme name. It was apparently inserted from the block.block.workflowtransitionform.yml config file which included theme: null.

a:13:{s:4:"uuid";s:36:"bfd525ec-6381-4504-be16-971368d5185a";s:8:"langcode";s:2:"en";s:6:"status";b:0;s:12:"dependencies";a:2:{s:6:"module";a:1:{i:0;s:8:"workflow";}s:5:"theme";a:1:{i:0;N;}}s:5:"_core";a:1:{s:19:"default_config_hash";s:43:"...";}s:2:"id";s:22:"workflowtransitionform";s:5:"theme";N;s:6:"region";s:0:"";s:6:"weight";i:-7;s:8:"provider";s:8:"workflow";s:6:"plugin";s:30:"workflow_transition_form_block";s:8:"settings";a:4:{s:2:"id";s:30:"workflow_transition_form_block";s:5:"label";s:24:"Workflow Transition form";s:13:"label_display";s:7:"visible";s:8:"provider";s:8:"workflow";}s:10:"visibility";a:0:{}}

Upgrading to Workflow 2.2.2 did not remedy this.
I manually updated the theme setting using MySQL Workbench and was then able to import the file view.

Comments

lkuttner created an issue.

johnv’s picture

Did you remove all files from the code base after updating to the new version?
There were several issues reported concerning the theme setting in block.block.workflowtransitionform.yml .
E.g., issue #3454189: hook_update_8003 to 8.x-1.8 installs optional block.block.workflowtransitionform config and breaks my site tried to sovle that.
Removing the file is the best option.

lkuttner’s picture

@johnv, No, I just did a normal Composer install.

johnv’s picture

That file should have been deleted with the following update. I trust you have ran update.php?

function workflow_update_8009(&$sandbox) {
  // In version 2.1.0. and 2.1.5
  // Remove configuration that was introduced in update_8003.
  $config_names = [
    'block.block.workflowtransitionform',
    'system.action.change_a_node_to_next_workflow_state',
    'system.action.change_a_node_to_new_workflow_state',
  ];

  foreach ($config_names as $config_name) {
    \Drupal::configFactory()->getEditable($config_name)->delete();
  }
}