Review main Merged

90256[TASK] Auto-configure Fluid ViewHelperResolver delegates

Simon Praetorius CR +2 V +2 Easy +9 −4 updated 08/12/25, 19:32

Commit message

With Fluid 4.3, the `ViewHelperResolverDelegateInterface` was
introduced, which allows to "take over" a full ViewHelper
namespace instead of just one ViewHelper instance. When Fluid
was updated to 4.3 in the Core, dependency injection was added
to ViewHelperResolver delegates. For this to work properly,
these services need to be defined as `public` since Fluid needs
to access them on-demand based on the namespaces defined
in the template.

This patch extends the existing auto-configuration for ViewHelpers
to also auto-configure ViewHelperResolver delegates as `public`
based on the implemented interface.

Review

  • Code review CR +2 Done
    • Stefan Bürk +2
    • Christian Kuhn +1
  • Verified V +2 Done
    • Stefan Bürk +2
    • Christian Kuhn +1
    • core-ci +1 CI

Issues 2

Files 2

Review log 1318

  1. Simon Praetorius uploaded patch set 1 08/05/25, 07:58

  2. core-ci voted on patch set 1 V +1 08/05/25, 08:05 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82790

  3. Simon Praetorius updated the commit message in patch set 2 V +1 08/05/25, 08:22

  4. Simon Praetorius updated the commit message in patch set 3 08/05/25, 08:23

  5. Simon Praetorius updated the commit message in patch set 4 08/05/25, 08:24

  6. core-ci voted on patch set 2 V +1 08/05/25, 08:30 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82792

  7. core-ci voted on patch set 3 V +1 08/05/25, 08:32 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82793

  8. core-ci voted on patch set 4 V +1 08/05/25, 08:34 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82794

  9. Simon Praetorius marked it ready for review 08/09/25, 15:44

  10. Simon Schaufelberger voted on patch set 4 CR +1 V +1 08/11/25, 09:57

  11. Andreas Kienast voted on patch set 4 CR +1 08/11/25, 13:30

  12. Stefan Bürk commented on patch set 4 08/11/25, 14:45

    Services.php:36

    ```suggestion // Tag ViewHelperResolver delegate services and configure them to be used by Fluid, // which currently cannot inject them properly $containerBuilder->registerForAutoconfiguration(ViewHelperResolverDelegateInterface::class)->addTag('fluid.resolverdelegate'); $containerBuilder->addCompilerPass(new \TYPO3\CMS\Core\DependencyInjection\PublicServicePass('fluid.resolverdelegate')); ``` Usually we implement compilerpasses as dedicated classes and not as anonymous function, and in case to make tagged services public we can use the EXT:core PublicServicePass. Literally, `setPublic(true)` for the autotagging could be used also (which we don't do anyway so I would stay with the current used construct (tagging + compilerpass). @simon@praetorius.me What do you think ? Note: CompilerPass namespace should be imported, used full qualifier for example above.
  13. Simon Praetorius uploaded patch set 5 CR +1 V +1 08/11/25, 18:37

  14. Simon Praetorius commented on patch set 5 08/11/25, 18:38

    Services.php:36 Reply

    Nice, wasn't aware of that class.
  15. core-ci voted on patch set 5 V +1 08/11/25, 18:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/83153

  16. Christian Kuhn voted on patch set 5 CR +1 V +1 08/12/25, 19:11

  17. Stefan Bürk voted on patch set 5 CR +2 V +2 08/12/25, 19:22

  18. Stefan Bürk merged patch set 6 08/12/25, 19:32