- Issue created by @wim leers
- 🇧🇪Belgium wim leers Ghent 🇧🇪🇪🇺
Related, but not the same: 🐛 Drupal does not recognize when the config is identical Active .
\Drupal\Core\Recipe\ConfigConfigurator
does:
if ($active_data = $active_configuration->read($config_name)) {
// @todo https://www.drupal.org/i/3439714 Investigate if there is any
// generic code in core for this.
unset($active_data['uuid'], $active_data['_core']);
if (empty($active_data['dependencies'])) {
unset($active_data['dependencies']);
}
$recipe_data = $recipe_storage->read($config_name);
if (empty($recipe_data['dependencies'])) {
unset($recipe_data['dependencies']);
}
// Ensure we don't get a false mismatch due to differing key order.
// @todo When https://www.drupal.org/project/drupal/issues/3230826 is
// fixed in core, use that API instead to sort the config data.
self::recursiveSortByKey($active_data);
self::recursiveSortByKey($recipe_data);
if ($active_data !== $recipe_data) {
throw new RecipePreExistingConfigException($config_name, sprintf("The configuration '%s' exists already and does not match the recipe's configuration", $config_name));
}
But that means that if:
that Recipes will WRONGLY throw this exception!
Active
11.2 🔥
recipe system
The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.
Related, but not the same: 🐛 Drupal does not recognize when the config is identical Active .