Skip to content
This repository has been archived by the owner on Feb 27, 2024. It is now read-only.

Error when activating WDS plugins #1061

Open
phanuelmutuma opened this issue Oct 20, 2022 · 3 comments
Open

Error when activating WDS plugins #1061

phanuelmutuma opened this issue Oct 20, 2022 · 3 comments

Comments

@phanuelmutuma
Copy link

Describe the bug
Fatal error: Uncaught TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, function "WDS_Headless_Core\activation_callback" not found or invalid function name in C:\xampp\htdocs\wordpress\wp-includes\class-wp-hook.php:307 Stack trace: #0 C:\xampp\htdocs\wordpress\wp-includes\class-wp-hook.php(331): WP_Hook->apply_filters('', Array) #1 C:\xampp\htdocs\wordpress\wp-includes\plugin.php(476): WP_Hook->do_action(Array) #2 C:\xampp\htdocs\wordpress\wp-admin\plugins.php(194): do_action('activate_wds-he...') #3 {main} thrown in C:\xampp\htdocs\wordpress\wp-includes\class-wp-hook.php on line 307

To Reproduce
Steps to reproduce the behavior:

  1. Install plugins via composer
  2. Try to activate either of the WDS plugins

Expected behavior
The plugins should activate normally without error

Desktop (please complete the following information):

  • OS: Windows 21H2
  • Browser Microsoft edge with Chromium
  • Version 90
@mrEckendonk
Copy link

@phanuelmutuma What is the version of PHP? It seems that PHP 8.1.x gives a Fatal error on several plugins.

@alexstandiford
Copy link

I was able to work around this by temporarily adding a couple require statements in each of the WDS plugins:

I opened a PR for one of them here to provide an example: WebDevStudios/wds-headless-core#12

@sdoigmm
Copy link

sdoigmm commented May 22, 2023

Same error today with PHP 8.1.9, switching to PHP 7.4.30 resolved it

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants