- Issue created by @emptyvoid
- πΊπΈUnited States emptyvoid
When this scenario occurs (which is now verfied 100% by 10 different users) the system corrupts the Drupal registry and no site visitor can view the site.
The only solution requires manually logging into the target HTTP server and issuing a drush cr to rebuilt the cache and Drupal registry.
Every new user which authenticates to view the site, immediately corrupts and registry and cache for all active users.This is a black flag bug.
- π¨π¦Canada Liam Morland Ontario, CA π¨π¦
Are you able to add a test that demonstrates this? That would help to get it solved and prevent a regression.
- πΊπ¦Ukraine pingwin4eg Zaporizhia πΊπ¦
I have a similar issue
TypeError: Drupal\Core\Entity\EntityFieldManager::{closure:Drupal\Core\Entity\EntityFieldManager::buildBaseFieldDefinitions():289}(): Argument #1 ($hook) must be of type callable, string given, called in web/core/lib/Drupal/Core/Extension/ModuleHandler.php on line 307
but right after the cache rebuilding. And I don't use the shield module, this issue is the only similar one appearing in google results. So I think the issue can be in Drupal core actually.
Drupal 11.1.6, PHP 8.4.5.
- πΊπ¦Ukraine pingwin4eg Zaporizhia πΊπ¦
Looks like a hook is trying to be invoked, but the module, which implements it, is not loaded.
- πΊπΈUnited States nicxvan
Does this help π¬ Drupal 11.2 upgrade causes \Drupal::$container is not initialized yet error Active
- π«π·France vbouchet
I suspect it is linked to https://www.drupal.org/project/shield/issues/3277210 π Shield middleware invokes hooks before modules are loaded, corrupting module_implements cache Needs work .
- πͺπͺEstonia ram4nd Tallinn
In 11.2.x I get "white screen of death", with this error:
TypeError: Drupal\shield\ShieldMiddleware::__construct(): Argument #2 ($config_factory) must be of type Drupal\Core\Config\ConfigFactoryInterface, Symfony\Component\HttpKernel\HttpKernel given, called in /var/www/html/core/lib/Drupal/Component/DependencyInjection/Container.php on line 259 in Drupal\shield\ShieldMiddleware->__construct() (line 110 of modules/contrib/shield/src/ShieldMiddleware.php). Drupal\shield\ShieldMiddleware->__construct() (Line: 259) Drupal\Component\DependencyInjection\Container->createService() (Line: 177) Drupal\Component\DependencyInjection\Container->get() (Line: 430) Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters() (Line: 237) Drupal\Component\DependencyInjection\Container->createService() (Line: 177) Drupal\Component\DependencyInjection\Container->get() (Line: 430) Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters() (Line: 237) Drupal\Component\DependencyInjection\Container->createService() (Line: 177) Drupal\Component\DependencyInjection\Container->get() (Line: 430) Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters() (Line: 237) Drupal\Component\DependencyInjection\Container->createService() (Line: 177) Drupal\Component\DependencyInjection\Container->get() (Line: 430) Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters() (Line: 237) Drupal\Component\DependencyInjection\Container->createService() (Line: 177) Drupal\Component\DependencyInjection\Container->get() (Line: 1467) Drupal\Core\DrupalKernel->getHttpKernel() (Line: 715) Drupal\Core\DrupalKernel->handle() (Line: 19)
- πΊπ¦Ukraine pingwin4eg Zaporizhia πΊπ¦
@ram4nd That is a totally different error. This issue is about
($hook) must be of type callable
, your error is($config_factory) must be of type Drupal\Core\Config\ConfigFactoryInterface
.