96938[TASK] Soft-fail and show broken site configurations
Commit message
Review
-
Code review CR +2 Done
- Garvin Hicking +2
- Oli Bartsch +1
- Matthias Vogel +1
-
Verified V +2 Done
- Garvin Hicking +2
- Oli Bartsch +1
- Matthias Vogel +1
- core-ci +1 CI
Issues 1
Files 41
- Build/Scripts/runTests.sh+1 −1
- typo3/sysext/backend/Classes/Controller/SiteConfigurationController.php+83 −13
- typo3/sysext/backend/Classes/Form/FormDataProvider/SiteDatabaseEditRow.php+8 −2
- typo3/sysext/backend/Classes/Form/FormDataProvider/SiteTcaInline.php+9 −3
- typo3/sysext/backend/Classes/Form/FormDataProvider/TcaSiteLanguage.php+7 −0
- typo3/sysext/backend/Resources/Private/Language/locallang_siteconfiguration.xlf+27 −0
- typo3/sysext/backend/Resources/Private/Partials/SiteManagement/InvalidSite.fluid.htmlnew+18 −0
- typo3/sysext/backend/Resources/Private/Templates/SiteConfiguration/Edit.fluid.html+10 −0
- typo3/sysext/backend/Resources/Private/Templates/SiteConfiguration/Overview.fluid.html+79 −1
- typo3/sysext/backend/Tests/Functional/Controller/Fixtures/InvalidSites/sites/broken-yaml/config.yamlnew+2 −0
- typo3/sysext/backend/Tests/Functional/Controller/Fixtures/InvalidSites/sites/invalid-language-base/config.yamlnew+13 −0
- typo3/sysext/backend/Tests/Functional/Controller/Fixtures/InvalidSites/sites/valid/config.yamlnew+8 −0
- typo3/sysext/backend/Tests/Functional/Controller/Fixtures/InvalidSites/pages.csvnew+5 −0
- typo3/sysext/backend/Tests/Functional/Controller/SiteConfigurationControllerInvalidSitesTest.phpnew+242 −0
- typo3/sysext/core/Classes/Command/SiteListCommand.php+16 −3
- typo3/sysext/core/Classes/Command/SiteValidateCommand.phpnew+168 −0
- typo3/sysext/core/Classes/Configuration/Loader/YamlFileLoader.php+7 −0
- typo3/sysext/core/Classes/Configuration/SiteConfiguration.php2+201 −40
- typo3/sysext/core/Classes/Exception/InvalidSiteConfigurationException.phpnew+36 −0
- typo3/sysext/core/Classes/Site/Entity/Site.php+46 −4
Show 21 more files
- typo3/sysext/core/Classes/Site/SiteFinder.php+13 −0
- typo3/sysext/core/Classes/Site/SiteSettingsFactory.php+1 −1
- typo3/sysext/core/Documentation/Changelog/14.3.x/Important-110913-BrokenSiteConfigurationsAreSkippedAndReported.rstnew+87 −0
- typo3/sysext/core/Tests/Functional/Command/CliCommandTest.php+2 −0
- typo3/sysext/core/Tests/Functional/Command/SiteValidateCommandTest.phpnew+102 −0
- typo3/sysext/core/Tests/Functional/Command/SiteValidateCommandValidSitesTest.phpnew+234 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/broken-csp/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/broken-csp/csp.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/broken-yaml/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/empty-env-base/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/invalid-base/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/invalid-base-variant/config.yamlnew+9 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/invalid-language-base/config.yamlnew+13 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/missing-locale/config.yamlnew+7 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/missing-root-page-id/config.yamlnew+1 −0
- typo3/sysext/core/Tests/Functional/Configuration/Fixtures/InvalidSites/valid/config.yamlnew+2 −0
- typo3/sysext/core/Tests/Functional/Configuration/SiteConfigurationInvalidSitesTest.phpnew+176 −0
- typo3/sysext/core/Tests/Unit/Configuration/SiteConfigurationTest.php+60 −3
- typo3/sysext/core/Tests/Unit/Site/Entity/SiteTest.php+40 −0
- typo3/sysext/frontend/Tests/Functional/SiteHandling/Fixtures/InvalidSiteTestPageImport.csvnew+13 −0
- typo3/sysext/frontend/Tests/Functional/SiteHandling/InvalidSiteTest.phpnew+90 −0
Review log 1419
-
Garvin Hicking uploaded patch set 1 10/20/26, 15:50
-
core-ci voted on patch set 1 V -1 10/20/26, 16:12 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111877
-
core-ci voted on patch set 1 V +1 10/20/26, 16:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111877
-
Matthias Vogel uploaded patch set 2
V +110/20/26, 18:27 -
core-ci voted on patch set 2 V +1 10/20/26, 18:43 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111908
-
Matthias Vogel voted on patch set 2 CR +1 V +1 10/20/26, 18:46
-
Oli Bartsch uploaded patch set 3
CR +1V +110/21/26, 07:32 -
Oli Bartsch commented on patch set 3 10/21/26, 07:35
Hi Garvin, I pushed to address some review findings. Please check if you agree: - Invalid sites are now logged when detected: load/resolve errors once per cache build, Site object errors per request. Before, nothing was logged in frontend requests. - Only configuration errors (YAML parse/loading/placeholder, InvalidSiteConfigurationException, UnexpectedValueException) are collected and cached. Exceptions from SiteConfigurationLoadedEvent listeners or \Error are thrown again, so a transient failure is not cached as an invalid site until the next cache flush. - site:validate now also validates the base and the base of every base variant (site and languages), not only the variant matching the CLI context. - SiteFinder::getSiteByPageId() no longer falls back to the outer site for pages of an invalid nested site, it throws SiteNotFoundException. - site:list uses the cached sites again. - Added InvalidSiteTest (frontend): a valid site renders while another is broken (fails without your patch with the original exception), and a page below a broken nested site gets a 404. Unit tests cover logging and listener exceptions. RST updated accordingly. -
core-ci voted on patch set 3 V +1 10/21/26, 07:46 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111974
-
Oli Bartsch voted on patch set 3 CR +1 V +1 10/21/26, 07:52
-
Garvin Hicking commented on patch set 3 10/21/26, 07:53
Reply
Yes, thanks, these reworks are very helpful. I don't use variants myself a lot so I was not thinking of this case. -
Garvin Hicking commented on patch set 3 10/21/26, 10:04
Adding @ben@bnf.dev into the mix to get his feedback, I'd like to not merge this without his feedback 😊 -
Matthias Vogel uploaded patch set 4
CR +1V +110/21/26, 10:53 -
Garvin Hicking commented on patch set 4 10/21/26, 10:58
SiteConfiguration.php:398Nice, I think this also has the benefit to make the flags more explicit in this place. IMPORTS/PLACEHOLDERS are a trigger.SiteConfiguration.php:407Having this optional is also a good benefit. -
core-ci voted on patch set 4 V +1 10/21/26, 11:02 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111999
-
Matthias Vogel voted on patch set 4 CR +1 V +1 10/22/26, 07:49
-
Oli Bartsch voted on patch set 4 CR +1 V +1 10/22/26, 20:06
-
Garvin Hicking commented on patch set 4 CR +2 V +2 10/30/26, 10:35
Reply
Talked about in our merger meeting. Fine to merge, may have follow-ups when he looks at it. -
Garvin Hicking merged patch set 5 10/30/26, 10:53