"WatchdogMailer" logger runs too early for @date.formatter to be injected, causing a fatal error on cache invalidation.

Created on 19 November 2025, 3 days ago

Problem/Motivation

After a lot of debugging and trial and error, we finally found the original issue of 🐛 $hook must be of type callable, string given, called in ModuleHandler Active . It seems, that the "WatchdogMailer" logger runs too early for the "@date.formatter" to be injected, causing a fatal error on cache invalidation.

Steps to reproduce

  • Install module
  • Run \Drupal::service('cache.discovery')->deleteAll() / invalidateAll()

Proposed resolution

Use the php native Date formatter.

Remaining tasks

User interface changes

API changes

Data model changes

📌 Task
Status

Active

Version

3.0

Component

Code

Created by

🇩🇪Germany Grevil

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024