MDVA-30357: sitemap generated by cron has wrong image URL

The MDVA-30357 patch fixes the issue with the wrong image URL being created by a cron generated sitemap in the Commerce Admin. This patch is available when the Quality Patches Tool (QPT) 1.0.6 is installed. Please note that the issue was fixed in Adobe Commerce 2.4.2.

Affected products and versions

  • Adobe Commerce (all deployment methods) 2.3.2 to 2.4.0
The patch might become applicable to other versions with new Quality Patches Tool releases. To check if the patch is compatible with your Adobe Commerce version, update the 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.


Sitemaps generated by cron in Adobe Commerce contain the wrong image URL path.

Steps to reproduce:

  1. In the Commerce Admin, create a new website, store, or store view.
  2. Add at least one product to each store, and add at least one image to each product.
  3. Enable Sitemap Generation By Schedule in Admin > Stores > Configuration > CATALOG > XML Sitemap > Generation Settings.
  4. Generate a sitemap for any of the two stores manually in Admin > Marketing > Site Map using a sitemap name like “sitemap.xml”.
    • Rename the file to something like “manual_sitemap.xml” or copy the file content to any text editor.
  5. Generate the same sitemap by cron job sitemap_generate.
  6. Compare the manually generated sitemap “manual_sitemap.xml” and the sitemap generated by cron “sitemap.xml”.

Expected results:

The cached sitemap image path URL is correct.

Actual results:

The sitemap generated by cron contains the wrong image path URL. If you try to open the image from “sitemap.xml”, it will show a default placeholder. Manually generated sitemap URLs are unaffected by this issue.

Apply the patch

To apply individual patches, use the following links depending on your deployment method:

To learn more about Quality Patches Tool, refer to:

For info about other patches available in QPT, refer to Patches available in QPT in our developer documentation.

To learn more about sitemaps, refer to these articles in our developer documentation: