Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I was doing a new install for someone who had installed and enabled the MailChimp module without loading the MailChimp PHP library. When accessing the MailChimp module configuration, a bad Drupal log is created. Here is the event:
stdClass Object
(
[wid] => 847
[uid] => 1
[severity] => 5
[type] => mailchimp
[timestamp] => 1383055105
[message] => Failed to load MailChimp PHP library. Please refer to the installation requirements.
[variables] => i:3;
[link] =>
[name] => admin
)
Line 295 has this:
$output = t($event->message, unserialize($event->variables));
1) Not sure why variables has "3" in it since the message has no variables defined.
2) According to the API docs for t(), the second parameter has to be an array.
I will be investigating. Because of this bad entry, none of the log will show.
Comment | File | Size | Author |
---|---|---|---|
#2 | mailchimp-2123077-WatchdogError.patch | 486 bytes | dpearcefl |
Comments
Comment #1
dpearcefl CreditAttribution: dpearcefl commentedFound it. Line 214 in mailchimp.module is:
when it should be:
Will check the latest dev version now.
Comment #2
dpearcefl CreditAttribution: dpearcefl commentedPatch attached. Now how do we deal with the bad watchdog log entries? Will look at an SQL query next.
Comment #3
dpearcefl CreditAttribution: dpearcefl commentedHere is the SQL query needed to fix the old log entries:
I guess this needs to go in as an update?
Comment #4
tripper54 CreditAttribution: tripper54 commentedDuplicate of #2063783: Watchdog message missing array parameter causing type error