After changing a product's url_key, it is possible it's url_path is not changed.
So if the experius_reindexcatalogurlrewrites:producturls command is ran the following data is used:
["entity_id"]=> string(4) "7038" ["attribute_set_id"]=> string(1) "4" ["type_id"]=> string(6) "simple" ["sku"]=> string(10) "460500-kit" ["has_options"]=> string(1) "0" ["required_options"]=> string(1) "0" ["created_at"]=> string(19) "2019-09-09 10:15:09" ["updated_at"]=> string(19) "2019-10-17 15:08:51" ["name"]=> string(29) "ADR bijrijderskit (verplicht)" ["url_key"]=> string(34) "adr-bijrijderskit-verplicht-460510" ["url_path"]=> string(38) "adr-bijrijderskit-verplicht-460500-kit" ["visibility"]=> string(1) "4" ["store_id"]=> string(1) "1"
Since the url_path is used for generating the url-rewrites, this will result rewrites based on the old url_key.
Suggested fix:
Regenerate a product's url_path before reindexing url_rewrites
After changing a product's url_key, it is possible it's url_path is not changed. So if the experius_reindexcatalogurlrewrites:producturls command is ran the following data is used:
["entity_id"]=> string(4) "7038" ["attribute_set_id"]=> string(1) "4" ["type_id"]=> string(6) "simple" ["sku"]=> string(10) "460500-kit" ["has_options"]=> string(1) "0" ["required_options"]=> string(1) "0" ["created_at"]=> string(19) "2019-09-09 10:15:09" ["updated_at"]=> string(19) "2019-10-17 15:08:51" ["name"]=> string(29) "ADR bijrijderskit (verplicht)" ["url_key"]=> string(34) "adr-bijrijderskit-verplicht-460510" ["url_path"]=> string(38) "adr-bijrijderskit-verplicht-460500-kit" ["visibility"]=> string(1) "4" ["store_id"]=> string(1) "1"
Since the url_path is used for generating the url-rewrites, this will result rewrites based on the old url_key.Suggested fix: Regenerate a product's url_path before reindexing url_rewrites