Review main Merged

97319[BUGFIX] Resolve pages new in a workspace along their workspace ancestry

Benni Mack CR +2 V +2 Normal +171 −15 updated 11/07/26, 21:43

Commit message

PageAncestryResolver resolves the ancestry of a page in a given
workspace. A page that is new in a workspace does not exist in live
or in another workspace, so its ancestry stayed empty when it was
resolved from there. BackendUserAuthentication::isInWebMount() did
not find it within a webmount, BackendUtility::getPagesTSconfig()
returned no page TSconfig of its parent pages, and the same applied
to SlugHelper and the page rootline of FormEngine. Walking the page
tree with BackendUtility::BEgetRootLine(), as before, found it.

The resolver now resolves a page new in a workspace along the
ancestry of its own workspace, if it is not found in the requested
one. Versions of live pages are resolved as their live page, as
before. The additional query is only executed if the ancestry of the
requested workspace is empty.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Georg Ringer +1
    • Oli Bartsch +1
    • Simon Schaufelberger +1
  • Verified V +2 Done
    • Benni Mack +2
    • Georg Ringer +1
    • Oli Bartsch +1
    • Simon Schaufelberger +1
    • core-ci +1 CI

Issues 2

Files 5

Review log 1114

  1. Benni Mack uploaded patch set 1 11/03/26, 11:46

  2. core-ci voted on patch set 1 V +1 11/03/26, 11:56 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113151

  3. Oli Bartsch commented on patch set 1 11/06/26, 13:03

    BackendUserAuthentication.php:347

    `BackendUtility::getPagesTSconfig()`, `SlugHelper::resolveParentPageRecord()` and the FormEngine rootline still resolve a page that is new in a workspace in the current workspace and get an empty ancestry. We should decide the semantics once, e.g. let `PageAncestryResolver::resolve()` resolve such a start page in its own workspace so all callers agree.
  4. Benni Mack commented on patch set 1 11/06/26, 13:21

    BackendUserAuthentication.php:347 Reply

    there are various changes in this pipeline already (and more about the PageAncestry) see https://review.typo3.org/c/Packages/TYPO3.CMS/+/97323
  5. Benni Mack uploaded patch set 2 V +1 11/06/26, 21:39

  6. Benni Mack commented on patch set 2 11/06/26, 21:40

    BackendUserAuthentication.php:347 Reply

    I double-checkc the other places... I moved the handling into PageAncestryResolver::resolve(): a page new in another workspace is resolved along the ancestry of its own workspace if the requested one has none, so getPagesTSconfig(), SlugHelper, FormEngine and isInWebMount() agree. The special case in isInWebMount() is gone.
  7. core-ci voted on patch set 2 V +1 11/06/26, 21:50 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113538

  8. Benni Mack uploaded patch set 3 V +1 11/06/26, 21:55

  9. core-ci voted on patch set 3 V +1 11/06/26, 22:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113542

  10. Simon Schaufelberger voted on patch set 3 CR +1 V +1 11/07/26, 10:27

  11. Georg Ringer voted on patch set 3 CR +1 V +1 11/07/26, 12:11

  12. Oli Bartsch voted on patch set 3 CR +1 V +1 11/07/26, 14:40

  13. Benni Mack voted on patch set 3 CR +2 V +2 11/07/26, 21:43

  14. Benni Mack merged patch set 4 11/07/26, 21:43