Function register_rest_route problem
-
Hi,
It’s seems that AI Engine is causing this error:
The register_rest_route function was called incorrectly. The namespace must not start or end with a slash. (This message was added in version 5.4.2.)
Any idea how to fix this?
-
Hi,
Do you have the exact line for this error? Also, 100% sure it comes from AI Engine?
Hi,
Sorry I’m not 100% sure if it’s AI Engine, but I know that it happens when I activate it and use it. I think maybe there is a disfunction with WooCommerce or another plugin, it happens when I activate Embedding only, here is the message from Query Monitor:
register_rest_route()
wp-includes/rest-api.php:51MeowPro_MWAI_Embeddings->rest_api_init()
wp-content/plugins/ai-engine-pro/premium/embeddings.php:51do_action('rest_api_init')
wp-includes/plugin.php:517rest_get_server()
wp-includes/rest-api.php:587rest_do_request()
wp-includes/rest-api.php:545rest_preload_api_request()
wp-includes/rest-api.php:2911array_reduce()
wp-includes/rest-api.php:2911Automattic\W\I\A\Settings->add_component_settings()
wp-content/plugins/woocommerce/src/Internal/Admin/Settings.php:146apply_filters('woocommerce_admin_shared_settings')
wp-includes/plugin.php:205Automattic\W\I\A\WCAdminSharedSettings->Automattic\W\I\A\{closure}()
wp-content/plugins/woocommerce/src/Internal/Admin/WCAdminSharedSettings.php:61Automattic\W\B\A\AssetDataRegistry->execute_lazy_data()
wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Assets/AssetDataRegistry.php:267Automattic\W\B\A\AssetDataRegistry->enqueue_asset_data()
wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Assets/AssetDataRegistry.php:368do_action('admin_print_footer_scripts')
wp-includes/plugin.php:517
-
This reply was modified 2 years, 7 months ago by
christodeus.
Hi, It seems that it was Jetpack that was causing a problem, now I don’t have anymore error message
Hi, I talked to fast, the problem is still there:
register_rest_route()
wp-includes/rest-api.php:51MeowPro_MWAI_Embeddings->rest_api_init()
wp-content/plugins/ai-engine-pro/premium/embeddings.php:51do_action('rest_api_init')
wp-includes/plugin.php:517rest_get_server()
wp-includes/rest-api.php:587rest_do_request()
wp-includes/rest-api.php:545rest_preload_api_request()
wp-includes/rest-api.php:2911array_reduce()
wp-includes/rest-api.php:2911Google\S\C\A\Assets->Google\S\C\A\{closure}()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:398Google\S\C\A\Script_Data->Google\S\C\A\{closure}()
wp-content/plugins/google-site-kit/includes/Core/Assets/Script_Data.php:51Google\S\C\A\Asset->before_print()
wp-content/plugins/google-site-kit/includes/Core/Assets/Asset.php:129Google\S\C\A\Assets->run_before_print_callbacks()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:1018Google\S\C\A\Assets->run_before_print_callbacks()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:1027Google\S\C\A\Assets->run_before_print_callbacks()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:1027Google\S\C\A\Assets->run_before_print_callbacks()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:1027Google\S\C\A\Assets->Google\S\C\A\{closure}()
wp-content/plugins/google-site-kit/includes/Core/Assets/Assets.php:157do_action('wp_print_scripts')
wp-includes/plugin.php:517wp_print_head_scripts()
wp-includes/script-loader.php:2177do_action('wp_head')
wp-includes/plugin.php:517wp_head()
wp-includes/general-template.php:3053load_template('wp-content/themes/my-listing/header.php')
wp-includes/template.php:785locate_template()
wp-includes/template.php:720get_header()
wp-includes/general-template.php:48
OK, so it was definitetly Google Site Kit which caused the errors. I have disabled it and now it works just fine. But so you know π
The topic ‘Function register_rest_route problem’ is closed to new replies.