Closed
Description
After complete all the steps to create a new custom index as described in the official devdoc guide (https://devdocs.magento.com/guides/v2.2/extension-dev-guide/indexing-custom.html)
if you go on admin's indexer list page a fatal error is thrown due to a partially wrong implementation of Magento\Indexer\Model\Indexer::getLatestUpdated
method called by Magento\Indexer\Model\Indexer\DependencyDecorator::getLatestUpdated
.
The result of the DependencyDecorator::getLatestUpdated
must be a string, but the Indexer::getLatestUpdated
method returns null
the very first time you access that backend page because no view is yet present.
Preconditions (*)
- Magento 2.2.7 (both community or commerce)
Steps to reproduce (*)
- Implementation of a custom index as the guide: https://devdocs.magento.com/guides/v2.2/extension-dev-guide/indexing-custom.html
- Login to backend
- Go to System > Index Management
Expected result (*)
Actual result (*)
- A fatal error with this exception:
PHP Fatal error: Uncaught TypeError: Return value of Magento\\Indexer\\Model\\Indexer\\DependencyDecorator::getLatestUpdated() must be of the type string, null returned in <magento_root>/vendor/magento/module-indexer/Model/Indexer/DependencyDecorator.php:240
Metadata
Metadata
Assignees
Labels
The issue has been fixed in 2.2 release lineThe issue has been fixed in 2.3 release lineGate 2 Passed. Manual verification of the issue description passedGate 3 Passed. Manual verification of the issue completed. Issue is confirmedGate 1 Passed. Automatic verification of issue format passedGate 4. Acknowledged. Issue is added to backlog and ready for developmentThe issue has been reproduced on latest 2.2 releaseThe issue has been reproduced on latest 2.3 release