cancel
Showing results for 
Search instead for 
Did you mean: 

ArgumentCountError when executing indexer_clean_all_changelogs cron job

ArgumentCountError when executing indexer_clean_all_changelogs cron job

In Magento 2.2.6, I've encountered an issue and here is log:

main.CRITICAL: Error when running a cron job {"exception":"[object] (RuntimeException(code: 0): Error when running a cron job at /usr/share/nginx/html/magento2/vendor/magento/module-cron/Observer/ProcessCronQueueObserver.php:324, ArgumentCountError(code: 0): Too few arguments to function Magento\\Framework\\Mview\\View\\Changelog::clear(), 0 passed in /usr/share/nginx/html/magento2/vendor/magento/framework/Interception/Interceptor.php on line 58 and exactly 1 expected at /usr/share/nginx/html/magento2/vendor/magento/framework/Mview/View/Changelog.php:116)"} []

This error is coming from this cron job: indexer_clean_all_changelogs. But not sure how to fix this. Does anyone know how to solve it or have the same problem?

2 REPLIES 2

Re: ArgumentCountError when executing indexer_clean_all_changelogs cron job

Hi @jonathan_huang 

 

You need to run upgrade dicompile and full deployment script

php -dmemory_limit=1G bin/magento setup:upgrade
php -dmemory_limit=1G bin/magento setup:di:compile
php bin/magento deploy:mode:set developer --skip-compilation
php bin/magento setup:static-content:deploy -f
php bin/magento cache:clean

 This can solve your problem

 ------------------------------------------------
If you've found one of my answers useful, please give"Kudos" or "Accept as Solution"

Re: ArgumentCountError when executing indexer_clean_all_changelogs cron job

Hi @syedhasan ,

Thanks for your reply! I'll run these commands to see if this issue is solved or not.

Thank you.