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

  1. Update the local/dev system, stage config changes
  2. Deploy updated file & config to the target system
  3. Run the update (e.g. drush updb)
  4. Drupal breaks, whitepages on page load, errors on drush cr and other interactions

Proposed resolution

Update the group_update_11401 hook to accomodate for already updated config.

Remaining tasks

Issue fork group-3628769

Command icon 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

ckaotik created an issue. See original summary.

ckaotik’s picture

I've created a merge request with a simple fallback check. Not sure if we need tests for this.

ckaotik’s picture

Issue summary: View changes
ckaotik’s picture

Status: Active » Needs review