Review main Merged

77369[TASK] Streamline TypoScript IncludeTree logic

Christian Kuhn CR +2 V +2 Hard +269 −258 updated 01/16/23, 09:32

Commit message

The patch comes with a couple of changes for
the TypoScript IncludeTree construct:

* Identifiers are now unique within a tree. This
  is needed especially in the Backend
  TypoScript -> Included Template files rendering:
  Before, showing content of single segments did
  not work due to duplicate identifiers.

* getIdentifier() is hardened to throw an
  exception if not initialized: This detail is
  only needed for non-cache analysis purposes and
  identifiers don't exist when getting trees from cache
  in Frontend.

* To allow file includes relative to a parent file
  include, they now have a "path" property that is
  properly hand over to child includes. Relative
  child includes now work with include_static
  sys_template includes as well.

* RootInclude now has an identifier as well to
  seed child includes which include the parent
  identifier in their hash.

* Identifier hashes and cache identifiers are built
  with fast xxh3 hash in favor of sha1() and
  json_encode() is used in favor of serialize()
  when hashing structures, if possible.

* Identifier hashes are created in the setter
  instead of calling hash() in the caller.

* [end] and [global] lines are now parts of the
  previous condition segment and don't create
  one-line segments anymore.

* Tests are adapted to be a bit less noisy on
  properties we're not interested in by using
  another custom comparator.

Review

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

Issues 2

Files 12

Review log 1117

  1. Christian Kuhn uploaded patch set 1 01/13/23, 01:25

  2. Christian Kuhn commented on patch set 1 01/13/23, 01:26

    needs to be done for template analyzer fixes.
  3. core-ci voted on patch set 1 V -1 01/13/23, 01:36 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35739

  4. Christian Kuhn uploaded patch set 2 V -1 01/13/23, 18:43

  5. core-ci voted on patch set 2 V +1 01/13/23, 18:51 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35776

  6. Christian Kuhn uploaded patch set 3 V +1 01/13/23, 19:00

  7. core-ci voted on patch set 3 V +1 01/13/23, 19:08 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35777

  8. Christian Kuhn updated the commit message in patch set 4 V +1 01/13/23, 19:31

  9. Christian Kuhn updated the commit message in patch set 5 01/13/23, 19:33

  10. core-ci voted on patch set 5 V +1 01/13/23, 19:41 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35780

  11. core-ci voted on patch set 4 V +1 01/13/23, 19:48 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35779

  12. Christian Kuhn uploaded patch set 6 V +1 01/13/23, 19:56

  13. core-ci voted on patch set 6 V +1 01/13/23, 20:08 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/35782

  14. Benni Mack voted on patch set 6 V +1 CR +1 01/14/23, 20:00

  15. Stefan Bürk voted on patch set 6 V +1 CR +1 01/15/23, 07:18

  16. Christian Kuhn voted on patch set 6 V +2 CR +2 01/16/23, 09:32

  17. Christian Kuhn merged patch set 7 01/16/23, 09:32