Magento 2 – Fix Argument 1 Passed to getProductFromLocalCache() Must Be String, Null Given

data-migrationmagento2migration

After migration Magento 1 to 2.3.4, I have facing an error on some product edit.

Argument 1 passed to
Magento\Catalog\Model\ProductRepository::getProductFromLocalCache()
must be of the type string, null given, called in
/srv/public_html/vendor/magento/module-catalog/Model/ProductRepository.php
on line 270

Can you please help me to resolve this error ?

Thank you

Best Answer

For affected product has no SKU. Add SKU for that product this error will be fixed. You can update directly from MySQL, the table name is: catalog_product_entity

Related Topic