Problem/Motivation

The website encountered an unexpected error. Please try again later.
TypeError: count(): Argument #1 ($value) must be of type Countable|array, null given in count() (line 62 of core/lib/Drupal/Core/Render/Element/Radios.php).

count() (Line: 62)
Drupal\Core\Render\Element\Radios::processRadios()
call_user_func_array() (Line: 1007)
Drupal\Core\Form\FormBuilder->doBuildForm() (Line: 1070)
Drupal\Core\Form\FormBuilder->doBuildForm() (Line: 574)
Drupal\Core\Form\FormBuilder->processForm() (Line: 320)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 134)
Drupal\views\Plugin\views\exposed_form\ExposedFormPluginBase->renderExposedForm() (Line: 1238)
Drupal\views\ViewExecutable->build() (Line: 70)
views_fieldsets_views_ui_display_tab_alter() (Line: 562)
Drupal\Core\Extension\ModuleHandler->alter() (Line: 381)
Drupal\views_ui\ViewEditForm->getDisplayTab() (Line: 204)
Drupal\views_ui\ViewEditForm->form() (Line: 106)
Drupal\Core\Entity\EntityForm->buildForm() (Line: 41)
Drupal\views_ui\ViewFormBase->buildForm()
call_user_func_array() (Line: 531)
Drupal\Core\Form\FormBuilder->retrieveForm() (Line: 278)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 48)
Drupal\Core\Entity\EntityFormBuilder->getForm() (Line: 230)
Drupal\views_ui\Controller\ViewsUIController->edit()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 564)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 158)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 80)
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: 23)
Stack\StackedHttpKernel->handle() (Line: 709)
Drupal\Core\DrupalKernel->handle() (Line: 19)

Steps to reproduce

  1. Add an exposed entity reference filter (e.g., Taxonomy term field)
  2. Leave "Autocomplete" as the "Selection type" in the filter settings
  3. Enable BEF on view
  4. Set BEF settings for filter to use checkbox/radios

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

CommentFileSizeAuthor
#3 3293884-3.patch1.55 KBnarendra.rajwar27
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

maxilein created an issue. See original summary.

maxilein’s picture

Maby this issue is related and a possible solution?
https://www.drupal.org/project/stacks/issues/3260080

narendra.rajwar27’s picture

Status: Active » Needs review
FileSize
1.55 KB

Adding patch.

hawkeye.twolf’s picture

Issue summary: View changes
pfrenssen’s picture

Issue tags: +PHP 8.1
smustgrave’s picture

Version: 8.x-5.x-dev » 6.0.x-dev
Status: Needs review » Needs work

Able to replicate the issue but patch did not solve the issue for me

siddharthjain’s picture

I think the above issue is not related to BEF, there has been open core issue for the same. Here is the link to the issue: https://www.drupal.org/project/drupal/issues/3252288