Problem/Motivation

TypeError: Drupal\simple_sitemap\Logger::__construct(): Argument #1 ($messenger) must be of type Drupal\Core\Messenger\MessengerInterface, Drupal\Core\Logger\LoggerChannel given, called in /public_html/core/lib/Drupal/Component/DependencyInjection/Container.php on line 261 in Drupal\simple_sitemap\Logger->__construct() (line 35 of modules/simple_sitemap/src/Logger.php).

Steps to reproduce

Attempted update from 4.2.2 to 4.2.3 fails with the TypeError message. Drupal version 10.5.6. I tried clearing cache before the update, but that didn't change anything.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

peter pulsifer created an issue. See original summary.

f0ns’s picture

Just noticed the same error on updating:

The website encountered an unexpected error. Try again later.

TypeError: Drupal\simple_sitemap\Logger::__construct(): Argument #1 ($messenger) must be of type Drupal\Core\Messenger\MessengerInterface, Drupal\Core\Logger\LoggerChannel given, called in /var/www/html/web/core/lib/Drupal/Component/DependencyInjection/Container.php on line 259 in Drupal\simple_sitemap\Logger->__construct() (line 35 of modules/contrib/simple_sitemap/src/Logger.php).

Don't have the time to dig into it now so rolled back for now.

f0ns’s picture

Fixed the issue on my side.

Also had to apply: https://www.drupal.org/project/simple_sitemap/issues/3264573

f0ns’s picture

Status: Active » Needs review
peter pulsifer’s picture

The changes seemed to fix the problem. I had to separately upload the new module and the new version of the simple_sitemap.services.yml file, but after doing so the update proceeded without a problem. I don't really see why double quotes are important, but they do seem to make a difference!