- Issue created by @ptmkenny
- 🇬🇧United Kingdom adamps
Thanks for the report. I was getting a lot of similar errors and I believe I fixed them with this commit. Please can you check if you still see the error with the latest dev version?
- Status changed to Closed: outdated
over 1 year ago 4:21pm 2 May 2023 - 🇬🇧United Kingdom adamps
Should be fixed as described in #2. Please re-open if you still hit the bug with the latest release
- 🇯🇵Japan ptmkenny
Thanks, I can confirm this is fixed in the current dev version!
- 🇨🇭Switzerland megadesk3000
Don't know exactly if this is the same issue, but when i am trying to enable the symfony_mailer module in its 1.x-dev version i get the following error:
www-data@9da9a3bd1635:/app$ drush en symfony_mailer In Container.php line 147: Circular reference detected for service "language_manager", path: "language_request_subscriber -> language_manager -> config.factory -> plugin.manager.email_builder -> entity_type.manager -> string_translation -> strin g_translator.locale.lookup". PHP Fatal error: Uncaught Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException: Circular reference detected for service "entity_type.manager", path: "user_last_access_subscriber -> entity_type.manager -> string_translation -> string_translator.locale.lookup -> config.factory -> plugin.manager.email_builder". in /app/web/core/lib/Drupal/Component/DependencyInjection/Container.php:147
- Status changed to Needs work
over 1 year ago 12:57pm 8 May 2023 - Status changed to Active
over 1 year ago 1:07pm 8 May 2023 - 🇨🇭Switzerland titouille
same problem as megadesk3000 on #5. After upgrading to 1.3.0-beta1, I can't add new modules if symfony_mailer is enabled, it cause a Circular reference detected error :
PHP Fatal error: Uncaught Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException: Circular reference detected for service "entity_type.manager", path: "user_last_access_subscriber -> entity_type.manager -> string_translation -> string_translator.locale.lookup -> config.factory -> plugin.manager.email_builder".
downgrading to 1.2.1 resolve the problem.
- 🇬🇧United Kingdom adamps
Thanks for the reports. It's not exactly the same issue, because it's no longer related to drush. The cause seems to be multi-language sites - which my test sites are not, so I don't hit it. Strange how each error message is slightly different from the others.
- 🇬🇧United Kingdom adamps
This was caused by ✨ Allow full management of override plugins Fixed .
Probably the fix is something like this, partly undoing some changes in the above issue:
- Create class
MailerConfigOverride
with tagconfig.factory.override
, and remove that tag fromEmailBuilderManager
. Although this class usesEmailBuilderManager
, it should not have it injected as that causes the loop. MailerConfigOverride::loadOverrides()
has a hard-coded test to ignore certain entries that are used during initialisation and would cause a loop, probably "core.extension", "symfony_mailer.settings" (see earlier patch → that was later revised to the current code). Then it calls\Drupal::service('plugin.manager.email_builder')->loadOverrides()
.
- Create class
- Status changed to Needs review
over 1 year ago 5:42pm 11 May 2023 - last update
over 1 year ago 5 pass - 🇬🇧United Kingdom adamps
Please can everyone seeing this bug please test this patch?
- 🇭🇰Hong Kong hswong3i
@AdamPS confirm #11 working for my DruStack, see https://github.com/drustack/composer-project-website-skeleton/commit/6dd...
Once patch applied and `drush -y cr`, site up and running once again, able to enable other else modules with no issue.
Thank you very much ;-)
- Status changed to RTBC
over 1 year ago 9:19am 12 May 2023 - Status changed to Fixed
over 1 year ago 1:44pm 12 May 2023 Automatically closed - issue fixed for 2 weeks with no activity.
- Status changed to Fixed
over 1 year ago 2:23pm 11 July 2023 - 🇮🇹Italy trickfun
I get same error but I can't apply the patch with dev and 1.3.0-rc1 version.
thank you - 🇸🇰Slovakia kaszarobert
I met the same problem by installing 1.3.0-rc1 and running drush commands later.
- 🇯🇴Jordan Rajab Natshah Jordan
Is the following issue related?
🐛 Circular reference detected for service symfony mailer config override in multilingual sites Fixed - 🇩🇪Germany kreatIL
Same or similar issue here after upgrading to 1.3.0-rc1 on Drupal 9.5.10 and PHP 8.1.16
Circular reference detected for service "entity_type.manager", path: "scheduler.manager -> date.formatter -> entity_type.manager -> string_translat ion -> string_translator.locale.lookup -> config.factory -> symfony_mailer.config_override -> plugin.manager.email_builder".