From b45d35267e3d8e9f62758edd3dd8af71207bca67 Mon Sep 17 00:00:00 2001 From: doxa-maps-88655c70 <88627970+doxa-maps-88655c70@users.noreply.github.com> Date: Thu, 24 Sep 2026 04:18:24 +0000 Subject: [PATCH] zone-census: default to this repo, not one author's worktree check:no-abs-paths started failing the moment check-zone-census.mjs arrived from main: line 24 fell back to resolve('/home/lk10x/.../wt-packet') -- an absolute path into one author's worktree. That gate's whole rule is "a clone must work on any machine", and it sits inside build:unlocked, so main went red for every builder rather than only for whoever lacked that directory. The override was never the problem: DOXA_REPO still wins and is untouched. Only the FALLBACK moved, to the idiom check-no-absolute-paths.mjs names in its own failure text and every sibling script here already uses -- resolve(dirname(fileURLToPath(import.meta.url)), '..'). The data it reads, plugin-designs/my-upg-100-list/data, is present in this repo, so the default now resolves for anyone who clones it, and a caller pointing at a different worktree still exports DOXA_REPO exactly as before. VERIFIED both directions: check:no-abs-paths 0, and check:zone-census itself 0 running on the derived default rather than skipping. --- internal/check-zone-census.mjs | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/internal/check-zone-census.mjs b/internal/check-zone-census.mjs index 2b5bd6129..6da27326a 100644 --- a/internal/check-zone-census.mjs +++ b/internal/check-zone-census.mjs @@ -17,11 +17,19 @@ // // Usage: node internal/check-zone-census.mjs [postersDir] import { readFileSync, existsSync, readdirSync } from 'node:fs' -import { resolve, join } from 'node:path' -import { pathToFileURL } from 'node:url' +import { resolve, join, dirname } from 'node:path' +import { pathToFileURL, fileURLToPath } from 'node:url' +// DOXA_REPO still wins, unchanged. Only the FALLBACK moved: it was an absolute path to one +// author's worktree (/home/…/wt-packet), which check:no-abs-paths rejects outright — "a clone must +// work on any machine" — and that gate is inside build:unlocked, so the whole build went red for +// every builder, not just for whoever lacked that directory. +// The replacement is the idiom check-no-absolute-paths.mjs names in its own failure text, and the +// one every sibling script here uses: resolve from this file. The data it reads +// (plugin-designs/my-upg-100-list/data) is present in this repo, so the default now resolves for +// anyone who clones it, and a caller pointing at a different worktree still exports DOXA_REPO. const REPO = process.env.DOXA_REPO - || resolve('/home/lk10x/Workspace/eco-dx/root-doxa-maps/wt-packet') + || resolve(dirname(fileURLToPath(import.meta.url)), '..') const DATA = join(REPO, 'plugin-designs', 'my-upg-100-list', 'data') const POSTERS = resolve(process.argv[2] || join(REPO, 'library', 'scripts', 'posters', 'out', 'posters'))