Needs work
Project:
Commerce Core
Version:
3.3.5
Component:
Other
Priority:
Major
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
29 Apr 2026 at 12:37 UTC
Updated:
30 Apr 2026 at 09:27 UTC
Jump to comment: Most recent
Upgrading from 3.3.4 to 3.3.5 I get the following error when trying to run drush updb after the composer update:
Circular reference detected for service "Drupal\Core\Logger\LoggerChannelFactoryInterface", path: "asset.js.collection_optimizer -> asset.js.optimizer -> logger.channel.default -> Drupal\Core\Logger\LoggerChannelFactoryInterface ->
logger.watchdog_mailer -> Drupal\commerce\Hook\CommerceHooks -> commerce.inbox_message_fetcher -> commerce.logger".
drush cr does NOT help.
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
Comment #2
anybody#3582355: Circular reference detected looks similar but different!
Comment #3
anybodyMaybe lazy-loading the logger is an alternative? Unsure if there's a pattern to solve this...?
Comment #5
anybodyphpstan won't be happy...
Comment #6
anybodyComment #7
jsacksick commentedHow come I never experience this on my installs... I wasn't affected by any of these related bugs in the projects I've upgraded...
This never seems to end.
Comment #8
jsacksick commentedSee CommerceCartHooks for a pattern you can follow, using the AutowireServiceClosure. Also, there is absolutely no reason for this to break from 3.3.5 and not from 3.3.4.
Comment #9
anybody@jsacksick looking at the entries this only seems to happen with custom logger. Yeah had similar issues in core in the past...
I understand, but I can for sure tell it happened...
Comment #10
jsacksick commentedAre you going to test the change suggested?
Comment #12
anybody@jsacksick yes, thanks!!
Like this? (MR!679)