Problem/Motivation
The update to 4.0.0-alpha2 is problematic when using config deployments. If you perform the update on one system, then stage the updated config, and then deploy and run the update hook on the target system, Drupal will break:
Uncaught PHP Exception Drupal\\Component\\Plugin\\Exception\\PluginNotFoundException: "The "" plugin does not exist. Valid plugin IDs for Drupal\\group\\Plugin\\Group\\Relation\\GroupRelationTypeManager are: group_node:foo, ..." at /opt/drupal/web/core/lib/Drupal/Component/Plugin/Discovery/DiscoveryTrait.php line 53
The reason for this is that the update hook group_update_11401 blindly writes what's in the config's content_plugin, even though the relation_type may have already been set.
Steps to reproduce
- Update the local/dev system, stage config changes
- Deploy updated file & config to the target system
- Run the update (e.g.
drush updb) - Drupal breaks, whitepages on page load, errors on
drush crand other interactions
Proposed resolution
Update the group_update_11401 hook to accomodate for already updated config.
Remaining tasks
Issue fork group-3628769
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
ckaotikI've created a merge request with a simple fallback check. Not sure if we need tests for this.
Comment #4
ckaotikComment #5
ckaotik