TypeError from prometheus_dispatch_event

Created on 7 August 2023, over 1 year ago

Problem/Motivation

TypeError thrown from from prometheus_dispatch_event on Drupal 10.

Steps to reproduce

Problem was discovered when running drush updb after upgrading to Drupal 10.
TypeError was thrown from prometheus_metrics when running ckeditor5 updates and it was not possible to finish running the updates.
However it can also be recreated on simpler operations such as drush ucrt TestUser.

Proposed resolution

The error occurs because the order prometheus_dispatch_event passes the arguments to $eventDispatcher->dispatch() is no longer correct when running on Drupal 10. The quickest fix is to catch the TypeError exception and resubmit the function call with the reversed arguments.

Remaining tasks

Write a patch implementing the above fix. (DONE - Attached to issue).
Test the patch.
Merge to a new version of module.

User interface changes

None.

API changes

None.

Data model changes

None.

🐛 Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

🇬🇧United Kingdom Griff Phillips

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

Comments & Activities

Production build 0.71.5 2024