{"data":{"id":"magento2-40557","source":"github-pr","sourceRef":"magento/magento2#40557","title":"Tier Price Storage Interface Delete Bug doesn't delete all Tier Prices","pr":{"number":40557,"url":"https://github.com/magento/magento2/pull/40557","author":"annv99","mergedAt":"2026-05-26T07:34:02Z","mergeCommit":"d4c4ff1b11c009b5ff0141a6f5f0edf2fa1d4fd4","headCommit":"6759611191d214136b4aee7209f0acf5fbe9ed3e","baseRef":"2.4-develop","diffSha256":"e12f2be5aa73a44bb6d1b693ccbf50a8a924b9cc5954ee9ebfaf7469d5319592"},"issues":[{"number":37949,"url":"https://github.com/magento/magento2/issues/37949","title":"Tier Price Storage Interface Delete Bug doesn't delete all Tier Prices","labels":["Area: Framework","Component: Catalog","Issue: Confirmed","Priority: P2","Progress: PR Created","Progress: done","Reported on 2.4.x","Reproduced on 2.4.x","Triage: Dev.Experience"],"kind":"human"}],"fixedIn":null,"containingTags":[],"reportedOn":"2.4.6-p2","codeMatch":{"2.4.6":"clean","2.4.6-p1":"clean","2.4.6-p2":"clean","2.4.6-p3":"clean","2.4.6-p4":"clean","2.4.6-p5":"clean","2.4.6-p6":"clean","2.4.6-p7":"clean","2.4.6-p8":"clean","2.4.6-p9":"clean","2.4.6-p10":"clean","2.4.6-p11":"clean","2.4.6-p12":"clean","2.4.6-p13":"clean","2.4.6-p14":"clean","2.4.6-p15":"clean","2.4.7":"clean","2.4.7-p1":"clean","2.4.7-p2":"clean","2.4.7-p3":"clean","2.4.7-p4":"clean","2.4.7-p5":"clean","2.4.7-p6":"clean","2.4.7-p7":"clean","2.4.7-p8":"clean","2.4.7-p9":"clean","2.4.7-p10":"clean","2.4.8":"clean","2.4.8-p1":"clean","2.4.8-p2":"clean","2.4.8-p3":"clean","2.4.8-p4":"clean","2.4.8-p5":"clean","2.4.9":"clean"},"affectedVersions":["2.4.6","2.4.6-p1","2.4.6-p2","2.4.6-p3","2.4.6-p4","2.4.6-p5","2.4.6-p6","2.4.6-p7","2.4.6-p8","2.4.6-p9","2.4.6-p10","2.4.6-p11","2.4.6-p12","2.4.6-p13","2.4.6-p14","2.4.6-p15","2.4.7","2.4.7-p1","2.4.7-p2","2.4.7-p3","2.4.7-p4","2.4.7-p5","2.4.7-p6","2.4.7-p7","2.4.7-p8","2.4.7-p9","2.4.7-p10","2.4.8","2.4.8-p1","2.4.8-p2","2.4.8-p3","2.4.8-p4","2.4.8-p5","2.4.9"],"components":["magento/module-catalog"],"files":[{"path":"app/code/Magento/Catalog/Model/Product/Price/TierPriceStorage.php","change":"modified","package":"magento/module-catalog"}],"stripped":{"tests":["app/code/Magento/Catalog/Test/Unit/Model/Product/Price/TierPriceStorageTest.php"],"docs":[],"outsideCode":[]},"linesChanged":1,"mergeBatched":false,"excluded":null,"sections":{"description":"Only the first tier price that match the conditions is deleted, because it doesn't take into account the website of the tier price.","stepsToReproduce":"1. Go to the admin edit page and edit a product information.\n2. Set product tier prices with identical information but different affected websites.\n3. Delete ALL product tier prices with TierPriceStorageInterface, to do this get all tier prices with the TierPriceStorageInterface and use the retrieved prices to delete them.\n\nTier Prices should look like this:\n\n![image](https://github.com/magento/magento2/assets/95677511/8c1d633e-bba7-48ba-9e39-9ce003cec8a6)","expectedResult":"All Tier prices are deleted.","actualResult":"Only the first tier price that match the conditions is deleted, because it doesn't take into account the website of the tier price.","source":"issue"},"signatures":[],"labels":{"area":["Framework"],"component":["Catalog"],"priority":"P2","severity":null,"reportedOn":["2.4.x"]},"categories":["Catalog/Product"],"triage":{"model":"@cf/cloudflare/clef","requestHash":"cb9f1d0b440a4589d6d413a6efb50a568ddd205a9224ba10de2bcb2718c27e27","isBugfix":0.9856,"changeKind":{"choice":"bugfix","probabilities":{"bugfix":0.9664,"feature":0.0061,"refactor":0.0084,"tests_only":0.0103,"docs_only":0.0044,"dependency":0.0044},"confidence":0.921},"scope":{"score":0.4556,"probabilities":{"0":0.6326,"1":0.2793,"2":0.0881},"confidence":0.2289},"risk":{"score":0.7048,"probabilities":{"0":0.5816,"1":0.1319,"2":0.2865},"confidence":0.1566},"area":{"choice":"catalog","probabilities":{"catalog":0.8501,"checkout":0.028,"customer":0.008,"admin":0.0605,"graphql_api":0.0083,"framework":0.0234,"frontend":0.0104,"other":0.0113},"confidence":0.6892},"securityRelevant":0.0086,"reportedVersion":{"choice":"2.4.6-p2","probabilities":{"2.4.0":0.0019,"2.4.0-p1":0.0023,"2.4.1":0.0021,"2.4.1-p1":0.0023,"2.4.2":0.0021,"2.4.2-p1":0.0025,"2.4.2-p2":0.0027,"2.4.3":0.0023,"2.4.3-p1":0.0026,"2.4.3-p2":0.0027,"2.4.3-p3":0.0024,"2.4.4":0.0025,"2.4.4-p1":0.0027,"2.4.4-p10":0.0028,"2.4.4-p11":0.0031,"2.4.4-p12":0.0029,"2.4.4-p13":0.0027,"2.4.4-p14":0.0028,"2.4.4-p15":0.0029,"2.4.4-p16":0.003,"2.4.4-p17":0.0028,"2.4.4-p18":0.0025,"2.4.4-p2":0.0034,"2.4.4-p3":0.002,"2.4.4-p4":0.0022,"2.4.4-p5":0.0025,"2.4.4-p6":0.0033,"2.4.4-p7":0.0026,"2.4.4-p8":0.0026,"2.4.4-p9":0.0026,"2.4.5":0.004,"2.4.5-p1":0.0031,"2.4.5-p10":0.0025,"2.4.5-p11":0.0036,"2.4.5-p12":0.0042,"2.4.5-p13":0.0033,"2.4.5-p14":0.0035,"2.4.5-p15":0.003,"2.4.5-p16":0.0032,"2.4.5-p17":0.0031,"2.4.5-p2":0.0032,"2.4.5-p3":0.0025,"2.4.5-p4":0.0033,"2.4.5-p5":0.003,"2.4.5-p6":0.004,"2.4.5-p7":0.0032,"2.4.5-p8":0.0029,"2.4.5-p9":0.0023,"2.4.6":0.0293,"2.4.6-p1":0.0385,"2.4.6-p10":0.004,"2.4.6-p11":0.0051,"2.4.6-p12":0.0051,"2.4.6-p13":0.0039,"2.4.6-p14":0.0042,"2.4.6-p15":0.0048,"2.4.6-p2":0.6156,"2.4.6-p3":0.0113,"2.4.6-p4":0.0072,"2.4.6-p5":0.0098,"2.4.6-p6":0.0138,"2.4.6-p7":0.0074,"2.4.6-p8":0.0064,"2.4.6-p9":0.0052,"2.4.7":0.0044,"2.4.7-p1":0.0045,"2.4.7-p10":0.0038,"2.4.7-p2":0.0041,"2.4.7-p3":0.0048,"2.4.7-p4":0.0053,"2.4.7-p5":0.0045,"2.4.7-p6":0.0058,"2.4.7-p7":0.0043,"2.4.7-p8":0.0037,"2.4.7-p9":0.0026,"2.4.8":0.0049,"2.4.8-p1":0.005,"2.4.8-p2":0.006,"2.4.8-p3":0.0062,"2.4.8-p4":0.0066,"2.4.8-p5":0.0046,"2.4.9":0.0058,"unspecified":0.0058},"confidence":0.3754},"backportWorthy":{"score":1.6355,"probabilities":{"0":0.0548,"1":0.2549,"2":0.6903},"confidence":0.3167}},"curated":{"title":"Fixes tier price delete() skipping identical prices on other websites","description":"The retrievePriceId() method in TierPriceStorage did not compare website_id when matching tier prices for deletion. When identical tier prices existed across different websites, only the first matching price was resolved, causing delete() to silently skip the rest. The fix adds website_id to the matching condition.","categories":["Catalog/Product"],"author":"claude-code/opus-5.5","date":"2026-10-06","reviewedBy":null},"tests":{"2.4.8-p5":{"before":"not-runnable","after":"error","adapted":false,"runAt":"2026-10-06T09:20:22.440Z","releaseCommit":"870a22c63d9d9b68fa3297962e2d5d5841115814","suites":{"unit":{"before":"not-runnable","after":"error","runAt":"2026-10-06T09:20:22.440Z"}}},"2.4.9":{"before":"fail","after":"pass","adapted":false,"runAt":"2026-10-06T09:20:23.684Z","releaseCommit":"755e34dd689021c5165db9d35ecff74f7dc51527","suites":{"unit":{"before":"fail","after":"pass","runAt":"2026-10-06T09:20:23.684Z"}}},"2.4.7-p10":{"before":"not-runnable","after":"error","adapted":false,"runAt":"2026-10-06T09:29:30.687Z","releaseCommit":"72561bf80652f57cc642a03e2c9a51d74a285b14","suites":{"unit":{"before":"not-runnable","after":"error","runAt":"2026-10-06T09:29:30.687Z"}}}}},"_documentation":"https://magento.watch/api","_description":"Upstream fix magento2-40557 details"}