cancel
Showing results for 
Search instead for 
Did you mean: 

USPS shipping method issue

USPS shipping method issue

Hello All

I face one issue in USPS shipping method in magento version 2.3.3 after enable these shipping method on checkout page not showing any shipping
on log file show the following error can you please suggest any solution regarfing.

Per our phone conversation the 500 response is logged as php error log entries in the following file:
/home/acb22631/logs/php-error.log

This entry repeats, within:
[07-Dec-2020 20:44:05 UTC] PHP Fatal error: Uncaught TypeError: Argument 1 passed to Magento\Catalog\Model\ProductRepository:Smiley TonguerepareSku() must be of the type string, null given, called in /chroot/home/acb22631//html/vendor/magento/module-catalog/Model/ProductRepository.php on line 793 and defined in /chroot/home/acb22631//html/vendor/magento/module-catalog/Model/ProductRepository.php:803

 

Thanks
Kapil Dixit

1 REPLY 1

Re: USPS shipping method issue

Hi @sushil_dikshit 

 

It seems like the product is missing sku information. Please check in admin to verify.

Check the file vendor/magento/module-catalog/Model/ProductRepository.php

/**
     * Converts SKU to lower case and trims.
     *
     * @param string $sku
     * @return string
     */
    private function prepareSku(string $sku): string
    {
        return mb_strtolower(trim($sku));
    }
---
Problem Solved Click Accept as Solution!:Magento Community India Forum