Review main Abandoned

78334[BUGFIX] Catch non-writable settings file in silent configuration upgrade

Andreas Kienast CR 0 V 0 Normal +61 −13 updated 06/16/23, 10:18

Commit message

If the settings.php file is write-protected and
`SilentConfigurationUpgradeService` attempts to do upgrades, booting the
Install Tool fails due to an early thrown exception.

The internal `ConfigurationManager` is adjusted to throw a new
specialized `ConfigurationNotWritableException`, which is caught in the
controller and logs the incident as an error.

Review

  • Code review CR 0
  • Verified V 0

Issues 1

Files 5

Review log 1013

  1. Andreas Kienast uploaded patch set 1 03/30/23, 12:57

  2. core-ci voted on patch set 1 V -1 03/30/23, 13:31 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/39870

  3. Andreas Kienast uploaded patch set 2 V -1 03/30/23, 13:38

  4. core-ci voted on patch set 2 V +1 03/30/23, 13:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/39871

  5. Chris Müller voted on patch set 2 V +1 03/30/23, 13:55

  6. Chris Müller voted on patch set 2 CR +1 03/30/23, 13:58

  7. Andreas Kienast uploaded patch set 3 CR +1 V +1 04/04/23, 12:11

  8. core-ci voted on patch set 3 V +1 04/04/23, 12:19 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/40085

  9. Oliver Klee voted on patch set 3 CR +1 04/04/23, 12:22

  10. Christian Kuhn commented on patch set 3 CR -1 04/05/23, 13:39

    The issue with this: What we do in SilentConfiguration is at least partially "crucial": We rely on the new config to be set / migrated properly throughout the system. When we just catch, log and ignore the exception, "anything" afterwards may fail. We're essentially opening a can of worms in the core that we still need to deal with old settings in the system by doing that. I'd suggest to fail hard instead: If the file is not writable and thus not migrateble by automatic updates, we should imho stop and ask for this to get fixed first. What do you think?
  11. Andreas Kienast commented on patch set 3 04/05/23, 13:45

    Reply

    Also fine for me. This basically means to abandon the patch as the cause of the issue is already known as mentioned in the ticket.
  12. Benni Mack updated the commit message in patch set 4 CR +1 V +1 05/03/23, 09:55

  13. Andreas Kienast abandoned the change 06/16/23, 10:18