Add a config override validator to throw an exception when settings.php or a module override something they shouldn't?

Created on 8 January 2015, over 10 years ago
Updated 25 April 2025, 1 day ago

Problem/Motivation

There are some configuration values that are coupled to other things in the system in such a way that overriding them would put Drupal into a nonsensical state. For example:

  • overriding core.extension without actually installing/uninstalling the modules
  • overriding values within field.storage.* that require changes to database schema to implement

Proposed resolution

  1. Option 1: do nothing other than document this in default.settings.php (see #2392319-69: Config objects (but not config entities) should by default be immutable β†’ ) and hope that modules that implement overrides steer clear as well.
  2. Option 2: add an event that allows subscribers to check the state of overrides and throw an exception if something is overridden that that subscriber doesn't find acceptable.
  3. Option 3: other ideas?

User interface changes

None

API changes

?

πŸ“Œ Task
Status

Postponed: needs info

Version

11.0 πŸ”₯

Component

configuration system

Created by

πŸ‡ΊπŸ‡ΈUnited States effulgentsia

Live updates comments and jobs are added and updated live.
  • stale-issue-cleanup

    To track issues in the developing policy for closing stale issues, [Policy, no patch] closing older issues

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

    Thank you for creating this issue to improve Drupal.

    We are working to decide if this task is still relevant to a currently supported version of Drupal. There hasn't been any discussion here for over 8 years which suggests that this has either been implemented or is no longer relevant. Your thoughts on this will allow a decision to be made.

    Since we need more information to move forward with this issue, the status is now Postponed (maintainer needs more info). If we don't receive additional information to help with the issue, it may be closed after three months.

    Thanks!

Production build 0.71.5 2024