URI is not valid and cannot be converted into a string
题
I'm struggling with an error that is thrown in the debug.log. The problem is that multiple indexers are not updated allthough the cronjobs are running.
Re-indexing by CLI is working properly on all indexers but that cannot be the solution.
The debug.log
[2020-09-17 05:25:12] main.ERROR: Cron Job indexer_reindex_all_invalid has an error: URI is not valid and cannot be converted into a string. Statistics: {"sum":0,"count":1,"realmem":0,"emalloc":0,"realmem_start":146800640,"emalloc_start":143814352} [] []
[2020-09-17 05:25:12] main.CRITICAL: URI is not valid and cannot be converted into a string {"exception":"[object] (Laminas\\Uri\\Exception\\InvalidUriException(code: 0): URI is not valid and cannot be converted into a string at /PATH/web/vendor/laminas/laminas-uri/src/Uri.php:363)"} []
I took a look at the specified line but it's just the function that throws the exception. How can i find the 'url' that is causing the problem?
Config:
- Magento 2.3.5.-p1
- PHP 7.3-Stable
Thanks
没有正确的解决方案
其他提示
This will be thrown if you for example have redirect result set up, and the URL for it is not set correctly.
For example:
$redirect = $this->resultFactory->create(ResultFactory::TYPE_REDIRECT);
$redirect->setUrl('a/b/c'); // this is missing = PROBLEM
return $redirect;