← back to New Import Viewer
staging manifests: every batch persists full id/SKU manifest to data/launch-batches/ (queue lines were counts-only = un-actionable); superseded pre-gate count-only batches via queue marker; restaged ALL netnew gated: 120,991 staged with manifests, 8,221 no-image BLOCKED, cowtan_tout (8,312) excluded per Steve 'never'
863ce65caa4a42908162d55ef86693787ceacc93 · 2026-06-10 07:38:45 -0700 · SteveStudio2
Files touched
M .gitignoreM data/launch-queue.jsonlM server.js
Diff
commit 863ce65caa4a42908162d55ef86693787ceacc93
Author: SteveStudio2 <stevestudio2@SteveStacStudio.lan>
Date: Wed Jun 10 07:38:45 2026 -0700
staging manifests: every batch persists full id/SKU manifest to data/launch-batches/ (queue lines were counts-only = un-actionable); superseded pre-gate count-only batches via queue marker; restaged ALL netnew gated: 120,991 staged with manifests, 8,221 no-image BLOCKED, cowtan_tout (8,312) excluded per Steve 'never'
---
.gitignore | 1 +
data/launch-queue.jsonl | 29 +++++++++++++++++++++++++++++
server.js | 11 +++++++++--
3 files changed, 39 insertions(+), 2 deletions(-)
diff --git a/.gitignore b/.gitignore
index b3d6efa..9d12bb6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -7,3 +7,4 @@ dist/
build/
.next/
data/imgcache/
+data/launch-batches/
diff --git a/data/launch-queue.jsonl b/data/launch-queue.jsonl
index 5c91436..ae96091 100644
--- a/data/launch-queue.jsonl
+++ b/data/launch-queue.jsonl
@@ -43,3 +43,32 @@
{"batchId":"launch-5000-445226-mq83q67h","action":"launch","mode":"draft","count":5000,"skus":5000,"at":"2026-06-10T13:25:40.205Z"}
{"batchId":"launch-5000-203438-mq83q68f","action":"launch","mode":"draft","count":5000,"skus":5000,"at":"2026-06-10T13:25:40.240Z"}
{"batchId":"launch-1234-1779040-mq83q692","action":"launch","mode":"draft","count":1234,"skus":1234,"at":"2026-06-10T13:25:40.262Z"}
+{"batchId":"launch-1-578518-mq85ivtu","action":"launch","mode":"draft","count":1,"skus":1,"at":"2026-06-10T14:15:59.394Z"}
+{"batchId":"unpublish-2-1874747-mq85ivuy","action":"unpublish","mode":"draft","count":2,"skus":2,"at":"2026-06-10T14:15:59.434Z"}
+{"type":"supersede","note":"all launch batches above (pre 2026-06-10T15:00Z) carried counts only — no id manifest — and predate the all-products-must-have-images gate. Superseded by the gated, manifested netnew batches below. Consumers MUST ignore non-manifest batches.","at":"2026-06-10T14:37:27.928Z"}
+{"batchId":"launch-4995-2036397-mq86bpva","action":"launch","mode":"draft","count":4995,"skus":4995,"manifest":"data/launch-batches/launch-4995-2036397-mq86bpva.json","at":"2026-06-10T14:38:24.699Z"}
+{"batchId":"launch-4999-28724-mq86bpxm","action":"launch","mode":"draft","count":4999,"skus":4999,"manifest":"data/launch-batches/launch-4999-28724-mq86bpxm.json","at":"2026-06-10T14:38:24.781Z"}
+{"batchId":"launch-4499-30576-mq86bpzh","action":"launch","mode":"draft","count":4499,"skus":4499,"manifest":"data/launch-batches/launch-4499-30576-mq86bpzh.json","at":"2026-06-10T14:38:24.847Z"}
+{"batchId":"launch-4990-448835-mq86bq1e","action":"launch","mode":"draft","count":4990,"skus":4990,"manifest":"data/launch-batches/launch-4990-448835-mq86bq1e.json","at":"2026-06-10T14:38:24.917Z"}
+{"batchId":"launch-4993-320572-mq86bq4e","action":"launch","mode":"draft","count":4993,"skus":4993,"manifest":"data/launch-batches/launch-4993-320572-mq86bq4e.json","at":"2026-06-10T14:38:25.025Z"}
+{"batchId":"launch-4998-61018-mq86bq74","action":"launch","mode":"draft","count":4998,"skus":4998,"manifest":"data/launch-batches/launch-4998-61018-mq86bq74.json","at":"2026-06-10T14:38:25.123Z"}
+{"batchId":"launch-4997-167412-mq86bq9n","action":"launch","mode":"draft","count":4997,"skus":4997,"manifest":"data/launch-batches/launch-4997-167412-mq86bq9n.json","at":"2026-06-10T14:38:25.214Z"}
+{"batchId":"launch-4999-153624-mq86bqc9","action":"launch","mode":"draft","count":4999,"skus":4999,"manifest":"data/launch-batches/launch-4999-153624-mq86bqc9.json","at":"2026-06-10T14:38:25.308Z"}
+{"batchId":"launch-4998-134189-mq86bqe7","action":"launch","mode":"draft","count":4998,"skus":4998,"manifest":"data/launch-batches/launch-4998-134189-mq86bqe7.json","at":"2026-06-10T14:38:25.377Z"}
+{"batchId":"launch-4996-7404-mq86bqg5","action":"launch","mode":"draft","count":4996,"skus":4996,"manifest":"data/launch-batches/launch-4996-7404-mq86bqg5.json","at":"2026-06-10T14:38:25.448Z"}
+{"batchId":"launch-4934-39012-mq86bqi4","action":"launch","mode":"draft","count":4934,"skus":4934,"manifest":"data/launch-batches/launch-4934-39012-mq86bqi4.json","at":"2026-06-10T14:38:25.519Z"}
+{"batchId":"launch-5000-560361-mq86bqk3","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-560361-mq86bqk3.json","at":"2026-06-10T14:38:25.590Z"}
+{"batchId":"launch-4923-934400-mq86bqm5","action":"launch","mode":"draft","count":4923,"skus":4923,"manifest":"data/launch-batches/launch-4923-934400-mq86bqm5.json","at":"2026-06-10T14:38:25.664Z"}
+{"batchId":"launch-5000-2270-mq86bqo1","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-2270-mq86bqo1.json","at":"2026-06-10T14:38:25.732Z"}
+{"batchId":"launch-5000-284721-mq86bqpv","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-284721-mq86bqpv.json","at":"2026-06-10T14:38:25.798Z"}
+{"batchId":"launch-5000-527614-mq86bqrs","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-527614-mq86bqrs.json","at":"2026-06-10T14:38:25.866Z"}
+{"batchId":"launch-5000-1778538-mq86bqtr","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-1778538-mq86bqtr.json","at":"2026-06-10T14:38:25.938Z"}
+{"batchId":"launch-4995-905657-mq86bqvo","action":"launch","mode":"draft","count":4995,"skus":4995,"manifest":"data/launch-batches/launch-4995-905657-mq86bqvo.json","at":"2026-06-10T14:38:26.008Z"}
+{"batchId":"launch-4730-909764-mq86bqxn","action":"launch","mode":"draft","count":4730,"skus":4730,"manifest":"data/launch-batches/launch-4730-909764-mq86bqxn.json","at":"2026-06-10T14:38:26.077Z"}
+{"batchId":"launch-4587-457843-mq86bqzi","action":"launch","mode":"draft","count":4587,"skus":4587,"manifest":"data/launch-batches/launch-4587-457843-mq86bqzi.json","at":"2026-06-10T14:38:26.144Z"}
+{"batchId":"launch-335-558689-mq86br0v","action":"launch","mode":"draft","count":335,"skus":335,"manifest":"data/launch-batches/launch-335-558689-mq86br0v.json","at":"2026-06-10T14:38:26.192Z"}
+{"batchId":"launch-4312-343774-mq86br2l","action":"launch","mode":"draft","count":4312,"skus":4312,"manifest":"data/launch-batches/launch-4312-343774-mq86br2l.json","at":"2026-06-10T14:38:26.254Z"}
+{"batchId":"launch-4804-473098-mq86br46","action":"launch","mode":"draft","count":4804,"skus":4804,"manifest":"data/launch-batches/launch-4804-473098-mq86br46.json","at":"2026-06-10T14:38:26.312Z"}
+{"batchId":"launch-3973-466437-mq86br5v","action":"launch","mode":"draft","count":3973,"skus":3973,"manifest":"data/launch-batches/launch-3973-466437-mq86br5v.json","at":"2026-06-10T14:38:26.373Z"}
+{"batchId":"launch-5000-315669-mq86br7q","action":"launch","mode":"draft","count":5000,"skus":5000,"manifest":"data/launch-batches/launch-5000-315669-mq86br7q.json","at":"2026-06-10T14:38:26.440Z"}
+{"batchId":"launch-3934-2035693-mq86br9d","action":"launch","mode":"draft","count":3934,"skus":3934,"manifest":"data/launch-batches/launch-3934-2035693-mq86br9d.json","at":"2026-06-10T14:38:26.499Z"}
diff --git a/server.js b/server.js
index 5f17c28..77ad704 100644
--- a/server.js
+++ b/server.js
@@ -147,6 +147,10 @@ function send(res, code, body, type) {
}
// Stage an action to the append-only launch queue. NEVER writes to the store.
+// Each batch persists a FULL manifest (ids + skus + from-state) to
+// data/launch-batches/<batchId>.json — queue lines before 2026-06-10 carried
+// only counts, which made them un-actionable (a consumer had nothing to act
+// on). Manifested batches are the authoritative, image-gated staged set.
function stageAction({ ids, action, mode }) {
const idList = ids.join(',');
const rows = q(`SELECT vc.id, vc.vendor_code, vc.mfr_sku, vc.dw_sku, vc.pattern_name, ${SHOP_STATUS} AS st
@@ -156,9 +160,12 @@ function stageAction({ ids, action, mode }) {
const skus = rows.map(r => ({ id: +r[0], vendor: r[1], sku: r[2], dwSku: r[3], pattern: r[4], from: r[5] }));
const byVendor = {};
rows.forEach(r => (byVendor[r[1]] = (byVendor[r[1]] || 0) + 1));
+ const bdir = path.join(__dirname, 'data', 'launch-batches');
+ fs.mkdirSync(bdir, { recursive: true });
+ const manifest = path.join(bdir, batchId + '.json');
+ fs.writeFileSync(manifest, JSON.stringify({ batchId, action, mode, at: new Date().toISOString(), count: rows.length, skus }));
const qf = path.join(__dirname, 'data', 'launch-queue.jsonl');
- fs.mkdirSync(path.dirname(qf), { recursive: true });
- fs.appendFileSync(qf, JSON.stringify({ batchId, action, mode, count: rows.length, skus: rows.length, at: new Date().toISOString() }) + '\n');
+ fs.appendFileSync(qf, JSON.stringify({ batchId, action, mode, count: rows.length, skus: rows.length, manifest: 'data/launch-batches/' + batchId + '.json', at: new Date().toISOString() }) + '\n');
return { ok: true, staged: rows.length, action, mode, batchId, byVendor, live: false };
}
← 4fb4e88 HARD GATE: all products must have images (Steve 2026-06-10)
·
back to New Import Viewer
·
launch-queue CONSUMER: manifested batches → Shopify draft pr 24a8d83 →