On my site at http://139.59.47.100/ ,anyother url(http://139.59.47.100/daily-deals) except the home page is coming fine but for the homepage,i am getting the error "unable to serialize value".I have tried several fixes available for this like clearing the cache,recompiling,re deploying static assets etc.
Below is the exact error message.
{"0":"Unable to serialize value.","1":"#0 /var/www/html/vendor/magento/framework/App/PageCache/Kernel.php(153): Magento\Framework\Serialize\Serializer\Json->serialize(Array)\n#1 /var/www/html/vendor/magento/module-page-cache/Model/Controller/Result/BuiltinPlugin.php(96): Magento\Framework\App\PageCache\Kernel->process(Object(Magento\Framework\App\Response\Http\Interceptor))\n#2 /var/www/html/vendor/magento/framework/Interception/Interceptor.php(146): Magento\PageCache\Model\Controller\Result\BuiltinPlugin->afterRenderResult(Object(Magento\Framework\View\Result\Page\Interceptor), Object(Magento\Framework\View\Result\Page\Interceptor), Object(Magento\Framework\App\Response\Http\Interceptor))\n#3 /var/www/html/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Framework\View\Result\Page\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Response\Http\Interceptor))\n#4 /var/www/html/generated/code/Magento/Framework/View/Result/Page/Interceptor.php(130): Magento\Framework\View\Result\Page\Interceptor->___callPlugins('renderResult', Array, Array)\n#5 /var/www/html/vendor/magento/framework/App/Http.php(139): Magento\Framework\View\Result\Page\Interceptor->renderResult(Object(Magento\Framework\App\Response\Http\Interceptor))\n#6 /var/www/html/generated/code/Magento/Framework/App/Http/Interceptor.php(24): Magento\Framework\App\Http->launch()\n#7 /var/www/html/vendor/magento/framework/App/Bootstrap.php(257): Magento\Framework\App\Http\Interceptor->launch()\n#8 /var/www/html/index.php(39): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http\Interceptor))\n#9 {main}","url":"/","script_name":"/index.php"}
-
did you check why the value can't be serialized? Unfourtunatly magento2 won't tell you the exact problem why the value can't be serialized, but you can modify the code for dbugging purposes in order to print the json errorPhilipp Sander– Philipp Sander2019年01月04日 14:22:39 +00:00Commented Jan 4, 2019 at 14:22
1 Answer 1
I have encountered this. To get around it, I used this solution: https://magento.stackexchange.com/a/198109/69191
Other solutions are resetting permissions and flushing your Magento caches, including things like memcache and Redis.
-
I will try this and let you know.I have tried changing permissions and also flushing the default magento caches.Dhruv Marwha– Dhruv Marwha2019年01月05日 05:30:34 +00:00Commented Jan 5, 2019 at 5:30
-
Tried that solution but it did not work.Anything else that i can try?Dhruv Marwha– Dhruv Marwha2019年01月05日 06:08:52 +00:00Commented Jan 5, 2019 at 6:08