Make ConfigFactory::loadOverrides() public

Created on 15 March 2017, almost 8 years ago
Updated 31 January 2023, almost 2 years ago

Currently, config overrides offer (as far as I can tell) no introspection whatsoever. If you are not the config factory service, it's impossible to reliably determine all config overrides that are in effect. But for contrib modules that want to work around Core issues like πŸ› Inconsistencies when updating overridden config entities Needs work and πŸ› Display status message on configuration forms when there are overridden values Fixed until they are fixed, this information would be crucial in some cases, and in others at least make things a lot easier.

My simple suggestion: just make \Drupal\Core\Config\ConfigFactory::loadOverrides() a public method (and, of course, also adding it to the interface). Since, obviously, nothing can be using this method from the outside currently, it doesn't seem like this should have any unforeseen impact.
Well, at least as far as making the method public is concerned. I guess adding the method to the interface could break other implementations, so maybe this could be a follow-up for 8.4. But it would be really great if we could still get this change in for 8.3. These problems with config overrides really cause some hard-to-resolve bugs in contrib modules, and this would be a simple, yet effective way of making it easier to deal with them.

✨ Feature request
Status

Needs work

Version

10.1 ✨

Component
ConfigurationΒ  β†’

Last updated about 17 hours ago

Created by

πŸ‡¦πŸ‡ΉAustria drunken monkey Vienna, Austria

Live updates comments and jobs are added and updated live.
  • Needs tests

    The change is currently missing an automated test that fails when run with the original code, and succeeds when the bug has been fixed.

  • Needs change record

    A change record needs to be drafted before an issue is committed. Note: Change records used to be called change notifications.

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.

  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    This issue is being reviewed by the kind folks in Slack, #needs-review-queue-initiative. We are working to keep the size of Needs Review queue [2700+ issues] to around 400 (1 month or less), following Review a patch or merge request β†’ as a guide.

    If still a valid feature request it will need some tweaks.

    Any new functions or properties should be typehinted
    Will need to show test coverage
    Will need a change record to announce this new public function.

    Did not test btw

Production build 0.71.5 2024