If you were updating from an older version of HikaShop, I would have told you that it is normal as before that "force canonical URL on listings" option didn't exist and since a few versions is it present and activated by default. So if you had wrong canonical URLs on your products it would create that problem when upgrading. But from the 2.4.0 to the 2.5.0, I don't see why it would happen.
The first solution is simple, but I would rather recommend fixing the canonical URL setting of your products with a valid URL. Not only the URLs will still work, but it will help for your website SEO.