ACSD-65100: Removing the Maximum Width and Maximum Height values in the Media Gallery Image Optimization configuration causes an error
The ACSD-65100 patch fixes the issue where removing the Maximum Width and Maximum Height values in the Media Gallery Image Optimization configuration causes an error during the image optimization process. This patch is available when the Quality Patches Tool (QPT) 1.1.64 is installed. The patch ID is ACSD-65100. Please note that this issue is scheduled to be fixed in Adobe Commerce 2.4.9.
Affected products and versions
The patch is created for Adobe Commerce version:
- Adobe Commerce (all deployment methods) 2.4.7-p3
Compatible with Adobe Commerce versions:
- Adobe Commerce (all deployment methods) 2.4.4 - 2.4.7-P5
magento/quality-patches package to the latest version and check the compatibility on the Quality Patches Tool: Search for patches page. Use the patch ID as a search keyword to locate the patch.Issue
An error occurs during the image optimization process when the values for Maximum Width and Maximum Height are removed in the Media Gallery Image Optimization configuration.
Steps to reproduce:
-
Go to the Stores > Settings > Configuration > Advanced > System > Media Gallery Image Optimization.
-
Remove the values for Maximum Width and Maximum Height.
-
Clean the configuration cache.
-
Navigate to Content > Elements > Pages.
-
Open any page for editing.
-
In the content area:
- Select Add Layout > Row.
- Select Add Elements > Text.
- In the WYSIWYG editor, click Add Image.
- Upload an image and select Add Selected.
-
Check the
var/log/exception.logfile.
Expected results:
No errors.
Actual results:
An error similar to the following is logged:
report.ERROR: InvalidArgumentException: Invalid image dimensions. in /var/www/html/vendor/magento/framework/Image/Adapter/AbstractAdapter.php:630
Apply the patch
To apply individual patches, use the following links depending on your deployment method:
- Adobe Commerce or Magento Open Source on-premises: Quality Patches Tool > Usage in the Quality Patches Tool guide.
- Adobe Commerce on cloud infrastructure: Upgrades and Patches > Apply Patches in the Commerce on Cloud Infrastructure guide.
Related reading
To learn more about Quality Patches Tool, refer to:
- Quality Patches Tool: A self-service tool for quality patches in the Tools guide.