Merging data types leads to incomplete definition

Created on 23 March 2016, over 8 years ago
Updated 26 May 2023, over 1 year ago

Problem/Motivation

When a data type definition is built by combing two other definition (a data type definition with a sub definition) in \Drupal\Core\Config\TypedConfigManager::getDefinitionWithReplacement() the sub definition doesn't get fully built by looping through its parent definitions, so the resulting merged definition is incomplete.

I noticed this when the resulting merged definition did not inherit any of the mappings provided by the sub definition.

Proposed resolution

Loop through the parent definition types of the sub definition with \Drupal\Core\Config\TypedConfigManager::getDefinition() before merging.

Remaining tasks

Non blocking: 📌 Add tests for 3 dynamic merges to verify dynamic data types dependencies lead to complete definitions Active

User interface changes

NA

API changes

NA

Data model changes

NA (there is but now it will be what we thought it should be)

🐛 Bug report
Status

Fixed

Version

8.4 ⚰️

Component
Typed data 

Last updated 3 days ago

  • Maintained by
  • 🇦🇹Austria @fago
Created by

🇬🇧United Kingdom yanniboi UK

Live updates comments and jobs are added and updated live.
  • Contributed project blocker

    It denotes an issue that prevents porting of a contributed project to the stable version of Drupal due to missing APIs, regressions, and so on.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024