While opening page /en/admin/config/media/imce I see error message:

The website encountered an unexpected error. Please try again later.
ArgumentCountError: array_merge() does not accept unknown named parameters in array_merge() (line 121 of modules/imce/src/ImcePluginManager.php).

array_merge(Array, Array, Array, Array, Array)
call_user_func_array('array_merge', Array) (Line: 121)
Drupal\imce\ImcePluginManager->permissionInfo() (Line: 323)
Drupal\imce\Form\ImceProfileForm->permissionInfo() (Line: 248)
Drupal\imce\Form\ImceProfileForm->folderForm(0, Array) (Line: 214)
Drupal\imce\Form\ImceProfileForm->form(Array, Object) (Line: 106)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 532)
Drupal\Core\Form\FormBuilder->retrieveForm('imce_profile_edit_form', Object) (Line: 278)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 573)
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: 158)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 80)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->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: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 706)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

Comments

mjllc created an issue. See original summary.

mjllc’s picture

Issue summary: View changes
avpaderno’s picture

Version: 8.x-2.3 » 8.x-2.x-dev
guilhermevp’s picture

StatusFileSize
new124.01 KB

I was unable to recreate the error. More information about the steps to reproduce error are welcome.

avpaderno’s picture

Title: php8: array_merge() error while editing configuration profiles » array_merge() error while editing configuration profiles
Issue tags: +PHP 8.0
bramdriesen’s picture

Status: Active » Postponed (maintainer needs more info)
ladybug_3777’s picture

I am receiving this same error on my new development site but not on my production site.

I am not able to figure out what difference between the two servers is that would cause this issue since the environments are almost identical. One difference is the module was installed via composer on dev but I think manually installed on production. (I plan to test this install path and see if it is part of the problem)

Please let me know if I can provide additional information to help trouble shoot this.

This is my current setup:
Drupal 9.1.5
PHP 7.4.3
IMCE 8.x-2.3
mySQL 8

Error message:
The website encountered an unexpected error. Please try again later.
ArgumentCountError: array_merge() does not accept unknown named parameters in array_merge() (line 121 of modules/contrib/imce/src/ImcePluginManager.php).
array_merge(Array, Array, Array, Array, Array)
call_user_func_array('array_merge', Array) (Line: 121)
Drupal\imce\ImcePluginManager->permissionInfo() (Line: 323)
Drupal\imce\Form\ImceProfileForm->permissionInfo() (Line: 248)
Drupal\imce\Form\ImceProfileForm->folderForm(0, Array) (Line: 214)
Drupal\imce\Form\ImceProfileForm->form(Array, Object) (Line: 106)
Drupal\Core\Entity\EntityForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 532)
Drupal\Core\Form\FormBuilder->retrieveForm('imce_profile_edit_form', Object) (Line: 278)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 73)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 573)
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: 158)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 80)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->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: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 52)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 706)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

ladybug_3777’s picture

Status: Postponed (maintainer needs more info) » Active
guilhermevp’s picture

Unable to reproduce the error again. Tried install the stable version through composer, tired the dev version through cloning and the error didn't showed up. Let's keep this open though, we need more info to reproduce the error consistently.

bramdriesen’s picture

Status: Active » Postponed (maintainer needs more info)

Unless we have more information on how to reproduce it, not much we can do.

bramdriesen’s picture

Category: Bug report » Support request
ladybug_3777’s picture

StatusFileSize
new552 bytes

We are still comparing differences on all our servers, but based on the research I've done on other Drupal modules with a similar array_merge errors I've created this patch file. I suspect the version of PHP is causing the problem.

Please feel free to review and provide feedback on this solution.

  • ufku committed 4735586 on 8.x-2.x
    Issue #3194147: Fixed PHP8 call_user_func_array() bug
    
    https://bugs.php....
ufku’s picture

Category: Support request » Bug report
Status: Postponed (maintainer needs more info) » Fixed

It seems to be bug with PHP8 https://bugs.php.net/bug.php?id=80531

Fixed in the dev branch. Thanks for reporting and the patch.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.