← back to Dw Validator Debug TK11314
Kravet roll-add: harden unit-mismatch ceiling — drop the width exemption so high-price per-yard products (Brunschwig metallics @ $5906/yd) can't slip through with a per-roll label
67771259807678c408353f19b694b42b96d971ca · 2026-08-18 15:43:05 -0700 · Steve
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Files touched
M shopify/scripts/cadence/add-kravet-roll-variants.js
Diff
commit 67771259807678c408353f19b694b42b96d971ca
Author: Steve <steve@designerwallcoverings.com>
Date: Tue Aug 18 15:43:05 2026 -0700
Kravet roll-add: harden unit-mismatch ceiling — drop the width exemption so high-price per-yard products (Brunschwig metallics @ $5906/yd) can't slip through with a per-roll label
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
---
shopify/scripts/cadence/add-kravet-roll-variants.js | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/shopify/scripts/cadence/add-kravet-roll-variants.js b/shopify/scripts/cadence/add-kravet-roll-variants.js
index 94ecaae3..cdbe5727 100644
--- a/shopify/scripts/cadence/add-kravet-roll-variants.js
+++ b/shopify/scripts/cadence/add-kravet-roll-variants.js
@@ -158,9 +158,12 @@ function rollLabel(tags) {
// UNIT-MISMATCH GUARD (2026-08-18, Cody FIX-FIRST): never create a "Sold Per Single Roll"
// variant on a mural/panel/meter product. Signal = mural/panel/scenic/tapestry/embroider in
// title/tags, OR a high MAP with no detected roll width (bare label). Skip + emit metric.
+ // $1500 ceiling is a hard "not a single roll" line: verified no legit Kravet single roll
+ // exceeds it; everything above is per-yard (e.g. Brunschwig metallics @ $5906/yd) or per-panel
+ // silk — a width tag does NOT make those a roll, so do NOT exempt on width.
const ROLL_MAP_CEILING = 1500;
const muralish = /\b(mural|panel|scenic|tapestry|embroider)\b/i.test(`${c.title || ''} ${(p.tags || []).join(' ')}`);
- if (muralish || (c.map > ROLL_MAP_CEILING && !/In Wide/i.test(label))) {
+ if (muralish || c.map > ROLL_MAP_CEILING) {
skip++; console.log(` ⚠ SKIP-REVIEW (unit-mismatch?) ${c.mfr_sku} @ $${price} label:"${label}" ${(c.title || '').slice(0, 40)}`);
continue;
}
← 74ddf8b9 Kravet roll-add: add unit-mismatch guard (skip mural/panel/h
·
back to Dw Validator Debug TK11314
·
Kravet roll-add: gate candidates on has_sample_variant (not d2220252 →