Error when submitting a form

Created on 30 August 2022, about 2 years ago
Updated 22 February 2023, over 1 year ago

Problem/Motivation

When I have bypass validation enabled, I can no longer submit a form, even when it is filled in completely.
I get the following error (seen in the Report Logs):

TypeError: end(): Argument #1 ($array) must be of type array, null given in end() (line 418 of /site/web/core/modules/file/src/Element/ManagedFile.php)

#0 /site/web/core/modules/file/src/Element/ManagedFile.php(418): end()
#1 [internal function]: Drupal\file\Element\ManagedFile::validateManagedFile()
#2 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(282): call_user_func_array()
#3 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(238): Drupal\Core\Form\FormValidator->doValidateForm()
#4 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(238): Drupal\Core\Form\FormValidator->doValidateForm()
#5 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(238): Drupal\Core\Form\FormValidator->doValidateForm()
#6 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(238): Drupal\Core\Form\FormValidator->doValidateForm()
#7 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(118): Drupal\Core\Form\FormValidator->doValidateForm()
#8 /site/web/core/lib/Drupal/Core/Form/FormBuilder.php(588): Drupal\Core\Form\FormValidator->validateForm()
#9 /site/web/core/lib/Drupal/Core/Form/FormBuilder.php(498): Drupal\Core\Form\FormBuilder->processForm()
#10 /site/web/modules/contrib/webformnavigation/src/WebformNavigationHelper.php(394): Drupal\Core\Form\FormBuilder->submitForm()
#11 /site/web/modules/contrib/webformnavigation/src/WebformNavigationHelper.php(356): Drupal\webformnavigation\WebformNavigationHelper->validateSinglePage()
#12 /site/web/modules/contrib/webformnavigation/webformnavigation.module(207): Drupal\webformnavigation\WebformNavigationHelper->validateAllPages()
#13 [internal function]: webformnavigation_submission_validation()
#14 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(82): call_user_func_array()
#15 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(275): Drupal\Core\Form\FormValidator->executeValidateHandlers()
#16 /site/web/core/lib/Drupal/Core/Form/FormValidator.php(118): Drupal\Core\Form\FormValidator->doValidateForm()
#17 /site/web/core/lib/Drupal/Core/Form/FormBuilder.php(588): Drupal\Core\Form\FormValidator->validateForm()
#18 /site/web/core/lib/Drupal/Core/Form/FormBuilder.php(320): Drupal\Core\Form\FormBuilder->processForm()
#19 /site/web/core/lib/Drupal/Core/Controller/FormController.php(73): Drupal\Core\Form\FormBuilder->buildForm()
#20 /site/web/core/modules/layout_builder/src/Controller/LayoutBuilderHtmlEntityFormController.php(39): Drupal\Core\Controller\FormController->getContentResult()
#21 [internal function]: Drupal\layout_builder\Controller\LayoutBuilderHtmlEntityFormController->getContentResult()
#22 /site/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#23 /site/web/core/lib/Drupal/Core/Render/Renderer.php(564): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#24 /site/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
#25 /site/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#26 /site/vendor/symfony/http-kernel/HttpKernel.php(158): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#27 /site/vendor/symfony/http-kernel/HttpKernel.php(80): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#28 /site/web/core/lib/Drupal/Core/StackMiddleware/Session.php(58): Symfony\Component\HttpKernel\HttpKernel->handle()
#29 /site/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(48): Drupal\Core\StackMiddleware\Session->handle()
#30 /site/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#31 /site/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()
#32 /site/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(48): Drupal\page_cache\StackMiddleware\PageCache->handle()
#33 /site/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(51): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#34 /site/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#35 /site/web/core/lib/Drupal/Core/DrupalKernel.php(709): Stack\StackedHttpKernel->handle()
#36 /site/web/index.php(19): Drupal\Core\DrupalKernel->handle()
#37 {main}

Steps to reproduce

  1. Enable the Webform Navigation module
  2. Go to a multipage webform, and make sure both checkboxes "Allow forward navigation when the wizard progress bar is enabled" and "Prevent validation when the user presses the "Next Page" button" are selected on the "Third Party Settings".
  3. Create a fully filled in webform (or use Test to fill it in automatically), go through all the pages and finally click on Submit.
  4. The error given above appears

P.s.: It happens with all the Webforms I use. I am running the latest versions of Drupal (9.4.5) and the Webform module (6.1.3).

πŸ› Bug report
Status

Closed: cannot reproduce

Version

2.0

Component

Code

Created by

πŸ‡§πŸ‡ͺBelgium backelj

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States greggles Denver, Colorado, USA

    Without steps to reproduce reliably on the latest versions I'm going to close this as cannot reproduce. Please reopen if you can provide answers to #7.

Production build 0.71.5 2024