Error accessing the admin page

Created on 15 February 2024, 11 months ago

Problem/Motivation

Error accessing the admin page.

Steps to reproduce

Install the module and access : /admin/structure/block/list-inline-block

Error: Call to a member function label() on null in Drupal\list_inline_block\Controller\ListBlock->getBlock() (line 107 of modules/contrib/list_inline_block/src/Controller/ListBlock.php).
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 592)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 58)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 704)
Drupal\Core\DrupalKernel->handle() (Line: 19)

🐛 Bug report
Status

Active

Version

1.1

Component

Code

Created by

🇪🇸Spain cimo75

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @cimo75
  • 🇮🇳India sakthi_dev

    @cimo75, thanks for reporting. Could you please elaborate the reproducing steps in a fresh installation?

  • 🇮🇳India dineshkumarbollu

    Hi @cimo75

    In this patch /admin/structure/block/list-inline-block i am getting wsod error but error is not related to problem statement, providing the error below.

    TypeError: asort(): Argument #1 ($array) must be of type array, null given in asort() (line 158 of /var/www/html/diet/vb101/web/modules/contrib/list_inline_block/src/Controller/ListBlock.php)..

  • Status changed to Needs review 11 months ago
  • 🇮🇳India dineshkumarbollu

    Here is the patch for the error fixing in the /admin/structure/block/list-inline-block path, Attaching the screenshot after fixing the error.Thanks

  • 🇮🇳India dineshkumarbollu

    Providing new patch because in previous patch as some indentation issue.Thanks

  • 🇮🇳India sakthi_dev

    @dineshkumarbollu, The mentioned issue is fixed in 1.1.1 version. Could you please review it?

  • 🇪🇸Spain cimo75

    Hallo error persists both in 1.1.0 and dev.

  • 🇮🇳India Jasjeet Kaur Brar

    Yes, Encountering an error while accessing /admin/structure/block/list-inline-block
    https://prnt.sc/0_Wr_Qb1TwOe

  • 🇺🇸United States lhridley

    Different error, problem still exists on 1.1.1, Drupal 10.3:

    The website encountered an unexpected error. Try again later.
    
    AssertionError: Cannot load the "node" entity with NULL ID. in assert() (line 261 of core/lib/Drupal/Core/Entity/EntityStorageBase.php).
    Drupal\Core\Entity\EntityStorageBase->load(NULL) (Line: 104)
    Drupal\list_inline_block\Controller\ListBlock->getBlock(Object)
    call_user_func_array(Array, Array) (Line: 123)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 638)
    Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
    Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
    Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 53)
    Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 28)
    Drupal\Core\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 32)
    Drupal\big_pipe\StackMiddleware\ContentLength->handle(Object, 1, 1) (Line: 106)
    Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
    Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 53)
    Asm89\Stack\Cors->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 36)
    Drupal\Core\StackMiddleware\AjaxPageState->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 741)
    Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
    
  • 🇨🇭Switzerland handkerchief

    Core: 10.4.0
    Module: 1.1.1

    Error on /admin/structure/block/list-inline-block:

    Warning: Attempt to read property "entity" on null in Drupal\list_inline_block\Controller\ListBlock->getBlock() (line 103 of /modules/contrib/list_inline_block/src/Controller/ListBlock.php)

    Error: Call to a member function label() on null in Drupal\list_inline_block\Controller\ListBlock->getBlock() (line 103 in /modules/contrib/list_inline_block/src/Controller/ListBlock.php).
    
  • 🇨🇭Switzerland handkerchief

    This patch should help.

Production build 0.71.5 2024