Closed
Description
Preconditions (*)
- Magento 2.3.0
- PHP 7.1.25
Steps to reproduce (*)
- Go to systems -> Data Transfer -> Import and select products.
- Download sample file and just import this file. This should work fine. (Validation + import)
- Add columns for images: base_image,small_image,thumbnail_image and a image for these columns. For example: i used this image https://laurentvandessel.be/wp-content/uploads/2014/03/placeholder-750x451.png
- Validation works fine, import gives me
Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1
.
Expected result (*)
- I expect no errors and images to be linked to the product.
Actual result (*)
Further Debugging (*)
Magento/CatalogImportExport/Model/Import/Uploader.php , I noticed some changes with how Magento handles file uploads. It seems that the variable $filePath is set twice (L: 184 & L:191), second time the filePath is set; it also uses the $filePath variable again.
- Value for $filePath (L: 184) (with example image I used above): pub/media/import/placeholder-750x451.png
- Value for $filePath (L:191) pub/media/import/placeholder-750x451.pngplaceholder-750x451.png
Image from the first value exists, second obviously doesn't. Function _setUploadFile will fail because it will throw an Exception because the image doesn't exist.