Fix WSOD of admin/reports/updates/settings when update.settings is removed

Created on 19 April 2023, over 1 year ago
Updated 9 April 2024, 8 months ago

Problem/Motivation

I was testing πŸ› The exported configuration is missing the fetch settings; breaks fetch function after import Active , which was a daily bugsmash triage yesterday. During that I got a WSOD so I am making a new issue for that problem.

Steps to reproduce

  1. Delete the
  2. Import configurations (drush cim) (it will delete the database configurations)
  3. Got to )
  4. WSOD

Proposed resolution

TBD

Remaining tasks

Patch
Review
Commit
Open πŸ› The exported configuration is missing the fetch settings; breaks fetch function after import Active .

User interface changes

TBD

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Closed: won't fix

Version

11.0 πŸ”₯

Component
UpdateΒ  β†’

Last updated about 1 hour ago

  • Maintained by
  • πŸ‡ΊπŸ‡ΈUnited States @tedbow
  • πŸ‡ΊπŸ‡ΈUnited States @dww
Created by

πŸ‡³πŸ‡ΏNew Zealand quietone

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 issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

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.

  • Issue created by @quietone
  • First commit to issue fork.
  • last update over 1 year ago
    29,283 pass
  • @akozoriz opened merge request.
  • Status changed to Needs review over 1 year ago
  • Status changed to Needs work over 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States smustgrave

    Not sure if putting a check here is the right course. Could be hiding a deeper issue.

    Issue summary solution is TBD.

  • πŸ‡ΊπŸ‡¦Ukraine akozoriz

    @smustgrave For me, it's definitely what we should do - check if the value from the config is an array before sending it to the implode function. If config doesn't exist in our system - it returns NULL and generates an error when we put it to the implode.

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

    But why was NULL ever passed there to begin with?

    Not arguing against just want to make sure we aren't treating a symptom of a bigger problem.

  • πŸ‡ΊπŸ‡¦Ukraine akozoriz

    @smustgrave It returns NULL because the author did the following steps:
    1. Delete the sync/update.settings.yml
    2. Import configurations (drush cim) (it will delete the database configurations)

    That deletes 'update.settings' configuration from the active configuration. As a result, when we try to fetch 'update.settings' configuration to build UpdateSettingsForm, we will get NULL. If we properly handle this, we will build the config form and have the possibility save it and create a new 'update.settings' config.

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

    I don't believe this is a bug. I thought we're not supposed to "babysit broken", and that core doesn't want defensive code to handle the case where your config isn't updated, etc. If you intentionally destroy the default config supplied by the module, aren't you on your own?

  • πŸ‡¦πŸ‡ΊAustralia larowlan πŸ‡¦πŸ‡ΊπŸ.au GMT+10

    I think we should mark this as closed won't fix.
    When a module puts config in `config/install` it needs to be able to rely on its presence. This applies to whole config objects and their contents too.
    Removing it in this fashion is breaking the warranty.
    In D7 land variable_get took a fallback value but the config API doesn't support that by design - the object is expected to be present from the point of install.
    If everytime a module accessed a config object that it defined in config/install it had to make sure it still existed, we'd have to add a lot of code all over core.
    For those reasons I think this can be closed won't fix or works as designed.

  • Status changed to Closed: won't fix 8 months ago
  • πŸ‡ΊπŸ‡ΈUnited States dww

    Per #11, closing. Thanks!

Production build 0.71.5 2024