71084[BUGFIX] Fix TypoScriptFrontendController initialization in subrequests
Commit message
Review
-
Code review CR +2 Done
- Benjamin Franzke +2
- Simon Gilli +1
-
Verified V +2 Done
- Benjamin Franzke +2
- Simon Gilli +1
- core-ci +1 CI
Issues 1
Files 4
- typo3/sysext/frontend/Classes/Middleware/PrepareTypoScriptFrontendRendering.php+9 −12
- typo3/sysext/frontend/Classes/Middleware/ShortcutAndMountPointRedirect.php+10 −16
- typo3/sysext/frontend/Classes/Middleware/TypoScriptFrontendInitialization.php+3 −0
- typo3/sysext/frontend/Configuration/Services.yaml2+7 −0
Review log 1114
-
Simon Schaufelberger uploaded patch set 1 09/14/21, 17:12
-
Simon Schaufelberger commented on patch set 1 09/14/21, 17:15
I would like to cover this change with a functional or acceptance test but I need some support in doing that. Additionally I also want to know if this is the right approach to solve this bug or if there is an even better solution. -
core-ci voted on patch set 1 V +1 09/14/21, 17:27 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16714
-
crell commented on patch set 1 09/15/21, 16:06
As long as TSFE is stateful, it shouldn't be injected, so as gross as globals are this is probably the best solution. However, we should also include an additional test to verify the change. I'm not sure what that test would look like, though, as I thought I got all the relevant tests originally. :-/ -
Benjamin Franzke uploaded patch set 2 09/16/21, 15:58
-
Benjamin Franzke commented on patch set 2 09/16/21, 15:58
Reply
As discussed before, we should use a request attribute instead of GLOBALS and avoid injecting stateful services, yea. TypoScriptFrontendController isn't a service, but a propotype (it is shared: false). -
core-ci voted on patch set 2 V +1 09/16/21, 16:17 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16811
-
Simon Schaufelberger commented on patch set 2 09/16/21, 16:33
Services.yaml:19"is breaks" sounds strange. I guess "is" needs to be deleted. -
Benjamin Franzke uploaded patch set 3 09/16/21, 16:59
-
Benjamin Franzke commented on patch set 3 09/16/21, 16:59
Services.yaml:19ReplyRight, fixed… -
core-ci voted on patch set 3 V +1 09/16/21, 17:12 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16821
-
Simon Gilli voted on patch set 3 V +1 CR +1 09/16/21, 17:16
-
Benjamin Franzke voted on patch set 3 V +2 CR +2 09/16/21, 17:36
-
Benjamin Franzke merged patch set 4 09/16/21, 17:36