[object Object]

← back to Flock Fix Viewer

governance(TK-11370): make live-by-default Shopify writers dry-run by default

09bf1a10933023f9ba329da6149abcfd18b23814 · 2026-09-10 17:52:30 -0700 · Steve Abrams

Flip `DRY = argv.includes('--dry')` -> `DRY = !argv.includes('--apply')` so a
zero-argument run no longer fires customer-facing Shopify writes.

Backward compatible: `--dry` still means dry; `--apply` now required to write.
Only zero-arg invocations change behaviour, and every candidate was checked
against its launchd/cron/pm2/wrapper invocation sites first (4 scripts that a
cadence job runs flagless were EXCLUDED so this cannot silently disable them).

Verified: node --check/py_compile 87/87 with a positive control proving the
checker rejects an injected fault; argv truth-table negative test 5/5.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L53y4oP2itY3qeJ8WQgMzc

Files touched

Diff

commit 09bf1a10933023f9ba329da6149abcfd18b23814
Author: Steve Abrams <steve@designerwallcoverings.com>
Date:   Thu Sep 10 17:52:30 2026 -0700

    governance(TK-11370): make live-by-default Shopify writers dry-run by default
    
    Flip `DRY = argv.includes('--dry')` -> `DRY = !argv.includes('--apply')` so a
    zero-argument run no longer fires customer-facing Shopify writes.
    
    Backward compatible: `--dry` still means dry; `--apply` now required to write.
    Only zero-arg invocations change behaviour, and every candidate was checked
    against its launchd/cron/pm2/wrapper invocation sites first (4 scripts that a
    cadence job runs flagless were EXCLUDED so this cannot silently disable them).
    
    Verified: node --check/py_compile 87/87 with a positive control proving the
    checker rejects an injected fault; argv truth-table negative test 5/5.
    
    Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
    Claude-Session: https://claude.ai/code/session_01L53y4oP2itY3qeJ8WQgMzc
---
 add-sqft.mjs       | 2 +-
 fix-unit.mjs       | 2 +-
 reverse-june16.mjs | 2 +-
 update-flock.mjs   | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/add-sqft.mjs b/add-sqft.mjs
index 4a57332..6829110 100644
--- a/add-sqft.mjs
+++ b/add-sqft.mjs
@@ -4,7 +4,7 @@ import fs from 'fs'; import os from 'os'; import path from 'path';
 const SHOP='designer-laboratory-sandbox.myshopify.com';
 const TOKEN=fs.readFileSync(new URL('./.token',import.meta.url),'utf8').trim();
 const LEDGER=path.join(os.homedir(),'.claude/yolo-queue/executed-reversible/ledger.jsonl');
-const DRY=process.argv.includes('--dry');
+const DRY=!process.argv.includes('--apply');
 
 async function gql(q,v={}){const r=await fetch(`https://${SHOP}/admin/api/2024-10/graphql.json`,{method:'POST',headers:{'X-Shopify-Access-Token':TOKEN,'Content-Type':'application/json'},body:JSON.stringify({query:q,variables:v})});return r.json();}
 const sleep=ms=>new Promise(r=>setTimeout(r,ms));
diff --git a/fix-unit.mjs b/fix-unit.mjs
index b575787..c417565 100644
--- a/fix-unit.mjs
+++ b/fix-unit.mjs
@@ -3,7 +3,7 @@ import fs from 'fs'; import os from 'os'; import path from 'path';
 const SHOP='designer-laboratory-sandbox.myshopify.com';
 const TOKEN=fs.readFileSync(new URL('./.token',import.meta.url),'utf8').trim();
 const LEDGER=path.join(os.homedir(),'.claude/yolo-queue/executed-reversible/ledger.jsonl');
-const DRY=process.argv.includes('--dry');
+const DRY=!process.argv.includes('--apply');
 const NEWVAL='Priced Per Single Roll. Ships untrimmed (30" untrimmed / 27" trimmed width).';
 
 async function gql(q,v={}){const r=await fetch(`https://${SHOP}/admin/api/2024-10/graphql.json`,{method:'POST',headers:{'X-Shopify-Access-Token':TOKEN,'Content-Type':'application/json'},body:JSON.stringify({query:q,variables:v})});return r.json();}
diff --git a/reverse-june16.mjs b/reverse-june16.mjs
index 5dff295..41a43de 100644
--- a/reverse-june16.mjs
+++ b/reverse-june16.mjs
@@ -8,7 +8,7 @@ const SHOP = 'designer-laboratory-sandbox.myshopify.com';
 const TOKEN = fs.readFileSync(new URL('./.token', import.meta.url), 'utf8').trim();
 const LEDGER = path.join(os.homedir(), '.claude/yolo-queue/executed-reversible/ledger.jsonl');
 const SNAP = new URL('./reverse-june16-snapshot.json', import.meta.url);
-const DRY = process.argv.includes('--dry');
+const DRY = !process.argv.includes('--apply');
 const DAYS = new Set(['2026-06-15', '2026-06-16', '2026-06-17']);
 
 async function gql(query, variables = {}) {
diff --git a/update-flock.mjs b/update-flock.mjs
index 14a9081..6d6b767 100644
--- a/update-flock.mjs
+++ b/update-flock.mjs
@@ -7,7 +7,7 @@ import path from 'path';
 const SHOP = 'designer-laboratory-sandbox.myshopify.com';
 const TOKEN = fs.readFileSync(new URL('./.token', import.meta.url), 'utf8').trim();
 const LEDGER = path.join(os.homedir(), '.claude/yolo-queue/executed-reversible/ledger.jsonl');
-const DRY = process.argv.includes('--dry');
+const DRY = !process.argv.includes('--apply');
 
 async function gql(query, variables = {}) {
   const r = await fetch(`https://${SHOP}/admin/api/2024-10/graphql.json`, {

← 1b9bb1d auto-data-snapshot: 2026-09-03T13:47:49 (1 data files) — arc  ·  back to Flock Fix Viewer  ·  TK-12268: add creds-in-URL fetch guard (fleet pattern) to ga 7ae3e73 →