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.
Problem/Motivation
Steps to reproduce:
- Pull core 8.8
- install the cross bundle module
-
Error: Call to a member function get() on null in Drupal\jsonapi_cross_bundles\ResourceType\CrossBundleResourceTypeRepository->all() (line 18 of /Users/dawehner/www/d8/modules/jsonapi_cross_bundles/src/ResourceType/CrossBundleResourceTypeRepository.php) #0 /Users/dawehner/www/d8/core/modules/jsonapi/src/Routing/Routes.php(115): Drupal\jsonapi_cross_bundles\ResourceType\CrossBundleResourceTypeRepository->all() #1 [internal function]: Drupal\jsonapi\Routing\Routes->routes() #2 /Users/dawehner/www/d8/core/lib/Drupal/Core/Routing/RouteBuilder.php(146): call_user_func(Array) #3 /Users/dawehner/www/d8/core/lib/Drupal/Core/ProxyClass/Routing/RouteBuilder.php(83): Drupal\Core\Routing\RouteBuilder->rebuild() #4 /Users/dawehner/www/d8/core/lib/Drupal/Core/Extension/ModuleInstaller.php(342): Drupal\Core\ProxyClass\Routing\RouteBuilder->rebuild() #5 /Users/dawehner/www/d8/core/lib/Drupal/Core/ProxyClass/Extension/ModuleInstaller.php(83): Drupal\Core\Extension\ModuleInstaller->install(Array, true) #6 /Users/dawehner/www/d8/core/modules/system/src/Form/ModulesListConfirmForm.php(173): Drupal\Core\ProxyClass\Extension\ModuleInstaller->install(Array) #7 [internal function]: Drupal\system\Form\ModulesListConfirmForm->submitForm(Array, Object(Drupal\Core\Form\FormState)) #8 /Users/dawehner/www/d8/core/lib/Drupal/Core/Form/FormSubmitter.php(112): call_user_func_array(Array, Array) #9 /Users/dawehner/www/d8/core/lib/Drupal/Core/Form/FormSubmitter.php(52): Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object(Drupal\Core\Form\FormState)) #10 /Users/dawehner/www/d8/core/lib/Drupal/Core/Form/FormBuilder.php(591): Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object(Drupal\Core\Form\FormState)) #11 /Users/dawehner/www/d8/core/lib/Drupal/Core/Form/FormBuilder.php(320): Drupal\Core\Form\FormBuilder->processForm('system_modules_...', Array, Object(Drupal\Core\Form\FormState)) #12 /Users/dawehner/www/d8/core/lib/Drupal/Core/Controller/FormController.php(91): Drupal\Core\Form\FormBuilder->buildForm(Object(Drupal\system\Form\ModulesListConfirmForm), Object(Drupal\Core\Form\FormState)) #13 [internal function]: Drupal\Core\Controller\FormController->getContentResult(Object(Symfony\Component\HttpFoundation\Request), Object(Drupal\Core\Routing\RouteMatch)) #14 /Users/dawehner/www/d8/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array(Array, Array) #15 /Users/dawehner/www/d8/core/lib/Drupal/Core/Render/Renderer.php(573): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() #16 /Users/dawehner/www/d8/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext(Object(Drupal\Core\Render\RenderContext), Object(Closure)) #17 /Users/dawehner/www/d8/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) #18 /Users/dawehner/www/d8/vendor/symfony/http-kernel/HttpKernel.php(151): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() #19 /Users/dawehner/www/d8/vendor/symfony/http-kernel/HttpKernel.php(68): Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object(Symfony\Component\HttpFoundation\Request), 1) #20 /Users/dawehner/www/d8/core/lib/Drupal/Core/StackMiddleware/Session.php(57): Symfony\Component\HttpKernel\HttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #21 /Users/dawehner/www/d8/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(47): Drupal\Core\StackMiddleware\Session->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #22 /Users/dawehner/www/d8/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #23 /Users/dawehner/www/d8/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass(Object(Symfony\Component\HttpFoundation\Request), 1, true) #24 /Users/dawehner/www/d8/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(47): Drupal\page_cache\StackMiddleware\PageCache->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #25 /Users/dawehner/www/d8/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(52): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #26 /Users/dawehner/www/d8/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #27 /Users/dawehner/www/d8/core/lib/Drupal/Core/DrupalKernel.php(694): Stack\StackedHttpKernel->handle(Object(Symfony\Component\HttpFoundation\Request), 1, true) #28 /Users/dawehner/www/d8/index.php(19): Drupal\Core\DrupalKernel->handle(Object(Symfony\Component\HttpFoundation\Request)) #29 {main}.
Proposed resolution
Sync the code in the overridden all method
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Comment | File | Size | Author |
---|---|---|---|
#5 | 3091400-5.patch | 1.69 KB | mglaman |
#4 | 3091400-2.patch | 1.34 KB | dawehner |
#2 | 3091400-2.patch | 765 bytes | dawehner |
Comments
Comment #2
dawehnerIt seems like changing parent classes is hard :)
Comment #3
dawehnerThere seems further issues, investigating them.
Comment #4
dawehnerThis seems to be one of the problems.
Comment #5
mglamanAdds a bump to ^8.8@alpha since that has the breaking change in the property.
Comment #7
mglaman🙌thank you! onto the new issues 🙃