Review main Merged

82521[BUGFIX] Use matching site in extbase BE modules

Christian Kuhn CR +2 V +2 Easy +17 −0 updated 01/22/24, 12:21

Commit message

Extbase BE modules suffer from the conceptual mistake
of using FE TypoScript for configuration. Modules
not in page context pick the first root template
in the page tree as TS entry point.

The patch changes this awful handling to also use
the attached site object for this page to substitute
site settings used as constants in TS correctly.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
    • Georg Ringer +1
    • Garvin Hicking +1
    • Stefan Bürk +1
    • Nikita Hovratov +1
    • Benni Mack +1
  • Verified V +2 Done
    • Christian Kuhn +2
    • Georg Ringer +1
    • Garvin Hicking +1
    • Stefan Bürk +1
    • Nikita Hovratov +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 2

Files 1

Review log 910

  1. Christian Kuhn uploaded patch set 1 01/20/24, 00:18

  2. core-ci voted on patch set 1 V +1 01/20/24, 00:24 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/51834

  3. Georg Ringer voted on patch set 1 CR +1 V +1 01/20/24, 09:33

  4. Garvin Hicking commented on patch set 1 CR +1 01/20/24, 09:36

    Thank you, code looks good. I'll try on my instance next week, if not already merged by then. 🥸
  5. Nikita Hovratov voted on patch set 1 CR +1 V +1 01/20/24, 10:27

  6. Benni Mack voted on patch set 1 CR +1 V +1 01/20/24, 21:58

  7. Stefan Bürk voted on patch set 1 CR +1 V +1 01/21/24, 02:28

  8. Garvin Hicking commented on patch set 1 V +1 01/22/24, 08:40

    I've applied this patch to my v12 installation, where I use this TypoScript: ``` [{$pageUids} && {$pageUids.loginPage} && traverse(page, "uid") == {$pageUids.loginPage}] ``` and then open the backend and open the i.e. "Forms" extbase module, I still got this: ``` Mon, 22 Jan 2024 09:36:06 +0100 [ERROR] request="6ac8ff86eee87" component="TYPO3.CMS.Core.TypoScript.IncludeTree.Visitor.IncludeTreeConditionMatcherVisitor": Expression could not be parsed. - {"expression":"{$pageUids} && 139 && traverse(page, \"uid\") == 139"} ``` Adding the guards to the TypoScript was my initial try to prevent the error from happening (but didn't work of course purely by guarding). If I adapt my condition to this: ``` [{$pageUids.loginPage} && traverse(page, "uid") == {$pageUids.loginPage}] ``` it does work, which I guess is enough "guarding" for the code there. So yes, seems to resolve the issue, thank you!
  9. Christian Kuhn voted on patch set 1 CR +2 V +2 01/22/24, 12:21

  10. Christian Kuhn merged patch set 2 01/22/24, 12:21