89738[BUGFIX] Store and process site settings.yaml as a map
Commit message
Review
-
Code review CR +2 Done
- Benjamin Franzke +2
- Garvin Hicking +1
- Benjamin Kott +1
-
Verified V +2 Done
- Benjamin Franzke +2
- Garvin Hicking +1
- Benjamin Kott +1
- core-ci +1 CI
Issues 1
Files 21
- typo3/sysext/core/Classes/Settings/Settings.php+3 −4
- typo3/sysext/core/Classes/Settings/SettingsDiff.phprenamed+27 −16
- typo3/sysext/core/Classes/Settings/SettingsFactory.php2new+96 −0
- typo3/sysext/core/Classes/Settings/SettingsProviderInterface.phpnew+35 −0
- typo3/sysext/core/Classes/Settings/SettingValue.phpnew+30 −0
- typo3/sysext/core/Classes/Site/Entity/SiteSettings.php+50 −26
- typo3/sysext/core/Classes/Site/SiteSettingsFactory.php+26 −112
- typo3/sysext/core/Classes/Site/SiteSettingsProvider.phpnew+109 −0
- typo3/sysext/core/Classes/Site/SiteSettingsService.php+24 −11
- typo3/sysext/core/Documentation/Changelog/13.1/Feature-103437-IntroduceSiteSets.rst+1 −3
- typo3/sysext/core/Documentation/Changelog/13.4.x/Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst7new+75 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/LegacySettingsTree/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/LegacySettingsTree/settings.definitions.yamlnew+5 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/LegacySettingsTree/settings.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/SettingsMap/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/SettingsMap/settings.definitions.yamlnew+5 −0
- typo3/sysext/core/Tests/Functional/Fixtures/Extensions/test_site_settings/Configuration/Sets/SettingsMap/settings.yamlnew+1 −0
- typo3/sysext/core/Tests/Functional/Site/Entity/SiteSettingsTest.php+94 −1
- typo3/sysext/core/Tests/Unit/Configuration/SiteConfigurationTest.php+3 −1
- typo3/sysext/core/Tests/Unit/Settings/SettingsDiffTest.phprenamed+35 −34
Review log 2941
Show 1216 earlier messages
-
Benjamin Franzke uploaded patch set 1 06/17/25, 07:27
-
core-ci voted on patch set 1 V +1 06/17/25, 07:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80413
-
Benjamin Franzke uploaded patch set 2
V +106/17/25, 09:40 -
core-ci voted on patch set 2 V +1 06/17/25, 09:49 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80416
-
Garvin Hicking updated the commit message in patch set 3
V +106/17/25, 21:39 -
Garvin Hicking commented on patch set 3 06/17/25, 21:44
Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:73```suggestion a tree, since it is not known which tree node is key or a value. ``` -
core-ci voted on patch set 3 V +1 06/17/25, 21:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80439
-
Garvin Hicking commented on patch set 3 06/17/25, 22:06
SettingsProvider.php:49Should we use named arguments here, this is a DTO with PCPP? (also line below)Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:69Should we acknowledge that this comes at a "cost" of having duplication/redundancy in large setting files? (ie something like: settings.styles.content.color1 settings.styles.content.color2 settings.styles.sheets.color1 ... and that it might still be "acceptable" to keep this in non-GUI managed environments in tree-format? Or is the tree format subject to a soonish deprecation in your view? -
Benjamin Franzke uploaded patch set 4
V +106/18/25, 06:51 -
Benjamin Franzke commented on patch set 4 06/18/25, 06:51
SettingsProvider.php:49Replyack, fine by me. DoneImportant-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:69ReplyI tried to acknowledge that with the first sentence "This tree representation is easier to write". I was about to deprecate the tree-based view, but I then wanted to keep it for the 99% cases where it does not harm.. Let's put it that way: No decision has been taken yet ;) But it's actually the superior format, which I'd still recommend to use (threfore I wrote "advised"), to avoid any conflicts, once a setting is added. For example, given the following settings defined as a tree: ``` settings.styles.content.color1 settings.styles.content.color2 ``` One can never add `styles.content` as a setting key, since based on the tree representation this setting would get `{color1: …, color2: …}` assigned, which was not the intention. So, I'd like to grasp some feedback once we have the map. Maybe it's not that bad. The good part is: Copy&Paste from documentation is super easy, no need to pick the right indent level, as in form framework yaml configurations… ;) So maybe people will like it – I hope so.Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:71ReplyDoneImportant-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:73ReplyDone -
core-ci voted on patch set 4 V +1 06/18/25, 06:58 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80455
-
Garvin Hicking commented on patch set 4 06/18/25, 11:59
I've tried this with a settings.yaml file that held this: ``` myExtension: myKey: myEntry: 2750 plugin: bootstrap_package: settings: scss: min-contrast-ratio: 4.6 ``` with the patch applied, editing and saving this yields a file: ``` myExtension: myKey: myEntry: 2750 plugin.bootstrap_package.settings.scss.min-contrast-ratio: 4.6 ``` The "myExtension:..." settings are something that probably got removed from a dummy settings.definitions.yaml file of mine. It's ok that this is not touched IMO - even though it is now a mixture of both forms? However, the settings overview now show this mixed display: https://www.dropbox.com/scl/fi/m8fefcbcj5vvqoygf7z2u/Screenshot-2025-06-18-at-13.55.24.png?rlkey=9o8vxqdcz2caj1b41mvahejow&dl=0 ``` Custom Settings (3) plugin.bootstrap_package.settings.scss.min-contrast-ratio: 4.6 plugin\.bootstrap_package\.settings\.scss\.min-contrast-ratio: 4.6 myExtension.myKey.myEntry: 2750 ``` so both a way with escaped and non-escaped dots is shown...?Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:69ReplyThanks for explaining this in depth. I also see much benefit with a redundant style here. But reading the Changelog wasn't so clear to me whether the "old style" is about to be axed and if I'm forced to rewrite everything, or if I'm not facing the 1% I could just keep it as-is. I see that the intention is to nudge people into the direction, so I think we can keep the text as it is, since it supports this nudging. -
Garvin Hicking commented on patch set 4 06/18/25, 11:59
Reply
(unresolving) -
Benjamin Franzke commented on patch set 4 CR -1 06/18/25, 12:23
Reply
mixture of undefined settings is expected, as written in RST: > Existing anonymous settings … will be preserved as a tree but the escaped variant of the defined setting in the settings overview is not ok. I also saw this during development but thought I fixed it – seems I broke it again. Will check, thanks! -
Garvin Hicking rebased onto patch set 5
CR -1V +106/18/25, 12:45 -
Garvin Hicking commented on patch set 5 06/18/25, 12:48
Reply
(Sorry, I mistakenly created a GIT relation chain while working on another patch - I hope it only rebased this one. Mea culpa)
-
core-ci voted on patch set 5 V +1 06/18/25, 12:53 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80465
-
Benjamin Franzke uploaded patch set 6
V +106/20/25, 08:13 -
Benjamin Franzke commented on patch set 6 06/20/25, 08:13
Reply
Fixed, thx! -
core-ci voted on patch set 6 V +1 06/20/25, 08:21 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80520
-
Benjamin Franzke uploaded patch set 7
V +106/20/25, 08:23 -
core-ci voted on patch set 7 V +1 06/20/25, 08:32 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80524
-
Benjamin Franzke uploaded patch set 8
V +106/20/25, 13:01 -
core-ci voted on patch set 8 V +1 06/20/25, 13:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80530
-
Benjamin Franzke uploaded patch set 9
V +107/02/25, 12:53 -
core-ci voted on patch set 9 V +1 07/02/25, 13:01 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81243
-
Benjamin Franzke uploaded patch set 10
V +107/03/25, 12:38 -
core-ci voted on patch set 10 V +1 07/03/25, 12:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81280
-
Benjamin Kott voted on patch set 10 CR +1 V +1 07/03/25, 12:59
-
Garvin Hicking commented on patch set 11
CR +1V +107/03/25, 19:49Published edit on patch set 10. -
Garvin Hicking commented on patch set 11 CR +1 V +1 07/03/25, 19:51
Some cool goodies in this one with composition over inheritance and polishing, thanks for taking care of this. -
core-ci voted on patch set 11 V +1 07/03/25, 19:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81290
-
Simon Schaufelberger commented on patch set 11 07/03/25, 22:36
SettingsFactory.php:83final classes can't be extended, therefor this method can be private -
Benjamin Franzke uploaded patch set 12
CR +1V +107/04/25, 04:24 -
Benjamin Franzke commented on patch set 12 07/04/25, 04:24
SettingsFactory.php:83ReplyI honestly don't care, but hey, done… -
core-ci voted on patch set 12 V +1 07/04/25, 04:31 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81300
-
Garvin Hicking voted on patch set 12 CR +1 V +1 07/04/25, 05:43
-
Benjamin Kott voted on patch set 12 CR +1 V +1 07/04/25, 06:20
-
Benjamin Franzke voted on patch set 12 CR +2 V +2 07/04/25, 06:35
-
Benjamin Franzke merged patch set 13 07/04/25, 06:58
-
Lina Wolf commented on patch set 13 07/14/25, 10:00
Should we also change the site package generator on get.typo3.org? https://github.com/TYPO3/get.typo3.org/pull/496
Important-106894-SiteSettingsyamlIsNowStoredAsAMap.rst:71