None of the solutions works:
Magento 2.2: Unable to unserialize value?
Magento 2.2 error: Unable to unserialize value
Navigating to a page of the category, localhost/magento/en/shop?p=3
My error as below:
1 exception(s):
Exception #0 (InvalidArgumentException): Unable to serialize value.
Exception #0 (InvalidArgumentException): Unable to serialize value.
<pre>#1 Magento\Framework\App\PageCache\Kernel->process(&Magento\Framework\App\Response\Http\Interceptor#000000006184d2b80000000038bb4237#) called at [vendor/magento/module-page-cache/Model/Controller/Result/BuiltinPlugin.php:96]
#2 Magento\PageCache\Model\Controller\Result\BuiltinPlugin->afterRenderResult(&Magento\Framework\View\Result\Page\Interceptor#000000006184d61c0000000038bb4237#, &Magento\Framework\View\Result\Page\Interceptor#000000006184d61c0000000038bb4237#, &Magento\Framework\App\Response\Http\Interceptor#000000006184d2b80000000038bb4237#) called at [vendor/magento/framework/Interception/Interceptor.php:146]
#3 Magento\Framework\View\Result\Page\Interceptor->Magento\Framework\Interception\{closure}(&Magento\Framework\App\Response\Http\Interceptor#000000006184d2b80000000038bb4237#) called at [vendor/magento/framework/Interception/Interceptor.php:153]
#4 Magento\Framework\View\Result\Page\Interceptor->___callPlugins('renderResult', array(&Magento\Framework\App\Response\Http\Interceptor#000000006184d2b80000000038bb4237#), array(array('result-messages', 'result-builtin-c...', 'result-varnish-c...'), array('meigeeCompoResul...'))) called at [generated/code/Magento/Framework/View/Result/Page/Interceptor.php:130]
#5 Magento\Framework\View\Result\Page\Interceptor->renderResult(&Magento\Framework\App\Response\Http\Interceptor#000000006184d2b80000000038bb4237#) called at [vendor/magento/framework/App/Http.php:140]
#6 Magento\Framework\App\Http->launch() called at [generated/code/Magento/Framework/App/Http/Interceptor.php:24]
#7 Magento\Framework\App\Http\Interceptor->launch() called at [vendor/magento/framework/App/Bootstrap.php:258]
#8 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\Http\Interceptor#000000006184d2ba0000000038bb4237#) called at [index.php:39]
</pre>
This page works fine in my server, but duplicate it under local environment shows this error. Why?
Edit: Note, /shop?p=2
and /shop?p=4
work, but /shop?p=3
shows this error
serialize
function in you all extension. and use\Magento\Framework\Serialize\Serializer\Json
forserialize
anddeserialize
methods.