← back to Designerwallcoverings
TK-10895: post-verify must read the STOREFRONT, not the Admin API
a48f91245c16ba583964bd9a7f84018d53e94019 · 2026-09-10 11:14:40 -0700 · Steve
The executor's post-reorder check read the Admin API and reported HARD FAIL
'pos1 is $4.25' on all 10 products of the first live batch. The rendered
storefront showed the real price first on 10/10 - the writes were fine. That is
the FIFTH false reading of this exact defect from the Admin API on this ticket;
it returns a stale variant order after a GraphQL reorder.
Memo rule 6 already said 'verify from the rendered storefront, not the Admin
API'. I wrote that rule and then built the guard against the wrong oracle. The
sibling reprice script had it right. Now consistent.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Files touched
M scripts/tk10895-trancheB-golive-269.mjs
Diff
commit a48f91245c16ba583964bd9a7f84018d53e94019
Author: Steve <steve@designerwallcoverings.com>
Date: Thu Sep 10 11:14:40 2026 -0700
TK-10895: post-verify must read the STOREFRONT, not the Admin API
The executor's post-reorder check read the Admin API and reported HARD FAIL
'pos1 is $4.25' on all 10 products of the first live batch. The rendered
storefront showed the real price first on 10/10 - the writes were fine. That is
the FIFTH false reading of this exact defect from the Admin API on this ticket;
it returns a stale variant order after a GraphQL reorder.
Memo rule 6 already said 'verify from the rendered storefront, not the Admin
API'. I wrote that rule and then built the guard against the wrong oracle. The
sibling reprice script had it right. Now consistent.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
---
scripts/tk10895-trancheB-golive-269.mjs | 19 +++++++++++++++----
1 file changed, 15 insertions(+), 4 deletions(-)
diff --git a/scripts/tk10895-trancheB-golive-269.mjs b/scripts/tk10895-trancheB-golive-269.mjs
index 409b11d..1860a82 100644
--- a/scripts/tk10895-trancheB-golive-269.mjs
+++ b/scripts/tk10895-trancheB-golive-269.mjs
@@ -139,10 +139,21 @@ for (const [i, w] of work.entries()) {
else if (res.data.productVariantsBulkReorder.userErrors.length) bad = `userErrors ${JSON.stringify(res.data.productVariantsBulkReorder.userErrors)}`;
if (bad) { console.log(`${tag} HARD FAIL reorder — ${bad}`); warn++; }
else {
- await sleep(350);
- const chk = await api(`/products/${w.pid}.json`);
- const cv = [...(chk.body?.product?.variants || [])].sort((a,b)=>a.position-b.position);
- if (!(parseFloat(cv[0]?.price) > 50)) { console.log(`${tag} HARD FAIL — after reorder pos1 is $${cv[0]?.price}`); warn++; }
+ // VERIFY ON THE RENDERED STOREFRONT — the Admin API returns a stale variant order after a
+ // GraphQL reorder and has now produced FIVE false readings of this exact defect on this ticket.
+ // The storefront is what Google Merchant Center reads, so it is the only oracle that counts.
+ await sleep(1200);
+ let sf = null;
+ for (let a = 1; a <= 4 && !sf; a++) {
+ try { const r = await fetch(`https://designerwallcoverings.com/products/${p.handle}.json`);
+ if (r.ok) sf = (await r.json()).product; } catch {}
+ if (!sf) await sleep(1200 * a);
+ }
+ if (!sf) { console.log(`${tag} WARN — could not read storefront to verify (write itself succeeded)`); warn++; }
+ else {
+ const sv = [...sf.variants].sort((a,b)=>a.position-b.position);
+ if (!(parseFloat(sv[0]?.price) > 50)) { console.log(`${tag} HARD FAIL — storefront pos1 is $${sv[0]?.price}`); warn++; }
+ }
}
if (p.options?.[0]?.name && p.options[0].name !== 'Size') {
await api(`/products/${w.pid}.json`, { method: 'PUT', body: JSON.stringify({ product: { id: +w.pid, options: [{ id: p.options[0].id, name: 'Size' }] } }) });
← 24c73c5 auto-data-snapshot: 2026-09-10T11:08:25 (5 data files) — scr
·
back to Designerwallcoverings
·
TK-11357 action C: 15-min zero-price-orderable OUTCOME tripw 094abee →