Review main Ready for review

98078[BUGFIX] Log the requested URL for PHP errors

Benni Mack CR +1 V +1 Normal +108 −11 updated 11/26/26, 18:57

Commit message

The exception handler adds the requested URL to its log entries,
the error handler did not, so PHP warnings and errors logged in a
web request could not be traced back to the URL that caused them.

The error handler now adds the requested URL as "request_url" to
the log context, the same key the exception handler uses, and
appends it to the sys_log message. Tokens in the URL are anonymized
by the same code, which moves from AbstractExceptionHandler to a
shared trait. On the command line no URL is added.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 1
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/78/98078/1 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/78/98078/1 && git cherry-pick FETCH_HEAD

Review

  • Code review CR +1 Needs a vote
    • Oliver Klee +1
  • Verified V +1 Needs a vote
    • Oliver Klee +1
    • core-ci +1 CI

Merge conflicts 2

Issues 2

Files 4

Review log 34

  1. Benni Mack uploaded patch set 1 11/26/26, 16:38

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

  3. Markus Klein commented on patch set 1 11/26/26, 18:18

    I'd love to see the user-agent as well. It is almost always good so see if some bogus URL comes from a bot or not.
  4. Oliver Klee voted on patch set 1 CR +1 V +1 11/26/26, 18:57