Review 14.3 Merged

95409[BUGFIX] Reset page renderer when performing subrequest

Benjamin Kott CR +2 V +2 Normal +163 −18 updated 08/25/26, 08:31

Commit message

The `PageContentErrorHandler` renders a configured error page through an
internal subrequest. That subrequest reuses the `PageRenderer`
singleton, which still carries the state of the request that failed:
header data, footer data, JavaScript, CSS and inline assets of the
requested page end up in the error page and are cached with it.

The `PageRenderer` state is therefore reset before the subrequest runs.
`PageRenderer->reset()` is public and marked `@internal` now, so the
error handler can reach it.

A functional test covers an uncached plugin that answers with the 404
page and asserts that none of the requested page's state survives into
it. Three tests in `SiteRequestTest` covering the page based error
handler were skipped because the handler used to fetch the error page
over HTTP. Internal subrequests have been the default since v12, so
these tests are enabled again and now assert the rendered error page
instead of the status code alone.

This is an intermediate fix until subrequests stop sharing state with
the request they answer.

Review

  • Code review CR +2 Done
    • Benjamin Kott +2
  • Verified V +2 Done
    • Benjamin Kott +2
    • core-ci +1 CI

Issues 2

Files 8

Review log 46

  1. Benjamin Kott commented on patch set 1 08/25/26, 07:33

    Cherry Picked from branch main.
  2. core-ci voted on patch set 1 V -1 08/25/26, 07:41 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/107073

  3. Benjamin Kott uploaded patch set 2 V -1 08/25/26, 08:04

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

  5. Benjamin Kott voted on patch set 2 CR +2 V +2 08/25/26, 08:30

  6. Benjamin Kott merged patch set 3 08/25/26, 08:31