@bongos/core 1.19.152 → 1.19.154

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.bongos-core.json CHANGED
@@ -2,11 +2,11 @@
2
2
  "artifact": "bongos-core",
3
3
  "manifest_schema": 1,
4
4
  "generator": "scripts/gds/package-core.js",
5
- "core_version": "1.19.152",
6
- "core_contract": "1.19.152",
7
- "source_commit": "57dc9f163cb5625cf780805c8beca257e40771a9",
5
+ "core_version": "1.19.154",
6
+ "core_contract": "1.19.154",
7
+ "source_commit": "fbe11785041864be4c61ec8bb98507574cdd5f10",
8
8
  "source_ref": "HEAD",
9
- "built_at": "2026-08-16T15:32:33.424Z",
9
+ "built_at": "2026-08-16T15:55:19.456Z",
10
10
  "redaction": {
11
11
  "model": "docs-redacted+functional-verbatim",
12
12
  "docs_redacted": 304,
@@ -17,7 +17,7 @@
17
17
  "gate": "passed"
18
18
  },
19
19
  "file_count": 1579,
20
- "tree_sha256": "08344ee3c5fade79cafd7d56d0de9e5a08d542c27b67e1c7362213fb51fe6eb1",
20
+ "tree_sha256": "b118dbf9bacb9695248f0821386defeac7d1498742efe7e907383359eb1f070b",
21
21
  "files": [
22
22
  {
23
23
  "path": ".claude/skills/blocker-review/SKILL.md",
@@ -4187,12 +4187,12 @@
4187
4187
  {
4188
4188
  "path": "package-lock.json",
4189
4189
  "mode": "0000644",
4190
- "sha256": "bd55eac572b5c23a50a7e53328e42984a7b5f14a62bbe038648792c6ddf6b92f"
4190
+ "sha256": "9f78c537cd7c7914c01ae8fd732fa039c2c749e9ee7f4cf3395d6ce71d0070c8"
4191
4191
  },
4192
4192
  {
4193
4193
  "path": "package.json",
4194
4194
  "mode": "0000644",
4195
- "sha256": "e04229a40fcabca2604e6eec41b7b3c6a1c393701f2191f85b12bce1ac19faa1"
4195
+ "sha256": "d5a00856ea454cdbf92b96b9a2d536272b3dd0481cdf8ecdb92c6e5bff9ec6eb"
4196
4196
  },
4197
4197
  {
4198
4198
  "path": "public-docs/index.html",
@@ -4877,12 +4877,12 @@
4877
4877
  {
4878
4878
  "path": "scripts/gds/gen-repo-map.js",
4879
4879
  "mode": "0000644",
4880
- "sha256": "5b5a3a160dcf65745e052bb08a85a707cdae67ecab2228487fce15872783a673"
4880
+ "sha256": "138c53e17099ef3d5f8809f1be6311e07c4bdd4bd7dd6def2c7c6c57a2e8ba67"
4881
4881
  },
4882
4882
  {
4883
4883
  "path": "scripts/gds/gen-session-index.js",
4884
4884
  "mode": "0000644",
4885
- "sha256": "93b76f22c490a28cdf64a62795c3e7f67bf3b86d2a5331d8d4eed2550a2d89db"
4885
+ "sha256": "c7bdbd7f7a4d2647be17ad37b540afc35913db80d121000346256d57c065f9fa"
4886
4886
  },
4887
4887
  {
4888
4888
  "path": "scripts/gds/git-merge-regen.js",
@@ -5032,7 +5032,7 @@
5032
5032
  {
5033
5033
  "path": "scripts/gds/newcomer-floor.templates.json",
5034
5034
  "mode": "0000644",
5035
- "sha256": "84abea5b31457611ed8fa27d33e492d513535ba373f47ba1144c06a56923d1d0"
5035
+ "sha256": "71aea42030aaba504d29841b67de74e2c7c58d62d3a2cfc90996734e35c4236b"
5036
5036
  },
5037
5037
  {
5038
5038
  "path": "scripts/gds/newcomer-floor.test.js",
@@ -5782,7 +5782,7 @@
5782
5782
  {
5783
5783
  "path": "src/module-api.js",
5784
5784
  "mode": "0000644",
5785
- "sha256": "31253b17c39aa10433fe72daffaf8e1591082cb5d8bbac470957be0b2aea125f"
5785
+ "sha256": "0ab78138a36bd9d516a9dd8e3fed336297b4c87387fa6a2254811d5286d938ab"
5786
5786
  },
5787
5787
  {
5788
5788
  "path": "src/module-loader/catalog.js",
@@ -7457,7 +7457,7 @@
7457
7457
  {
7458
7458
  "path": "tests/repo_map.mjs",
7459
7459
  "mode": "0000644",
7460
- "sha256": "b88208852062b4e8c8efcb44380e13205cd4d5ece7eed4e6c340a0ea969b33a9"
7460
+ "sha256": "12fe5a30bfebce58aa179767590df53cc5f220a1f7257bded08aef94fbe43507"
7461
7461
  },
7462
7462
  {
7463
7463
  "path": "tests/reward_gate.mjs",
package/package-lock.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@bongos/core",
3
- "version": "1.19.152",
3
+ "version": "1.19.154",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@bongos/core",
9
- "version": "1.19.152",
9
+ "version": "1.19.154",
10
10
  "license": "AGPL-3.0-or-later",
11
11
  "dependencies": {
12
12
  "express": "^4.21.2",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bongos/core",
3
- "version": "1.19.152",
3
+ "version": "1.19.154",
4
4
  "description": "Cloud Bongos — the AI-first build platform core (GDS + platform surfaces + module system), installed as a versioned dependency (ADR 0108).",
5
5
  "license": "AGPL-3.0-or-later",
6
6
  "main": "src/platform-server.js",
@@ -24,6 +24,9 @@
24
24
  // node scripts/gds/gen-repo-map.js --check # write nothing; exit 2 if EITHER bucket would change
25
25
  // node scripts/gds/gen-repo-map.js --check-block # exit 2 only if a TRACKED nested block would change (the CI gate)
26
26
  // node scripts/gds/gen-repo-map.js --check-whole # exit 2 only if docs/repo-map.md would change
27
+ // node scripts/gds/gen-repo-map.js --whole-only # WRITE docs/repo-map.md only; never touch the
28
+ // # tracked nested blocks (what a SPARSE dev-box
29
+ // # checkout must use — task 1002962)
27
30
  // docs/repo-map.md is GITIGNORED + regenerated at deploy/box-fetch since ADR 0110 (task 1926);
28
31
  // only the nested-doc symbol blocks stay tracked, so CI gates the block bucket, not the whole file.
29
32
  // node scripts/gds/gen-repo-map.js --json # print the extracted model as JSON (debug)
@@ -463,6 +466,21 @@ function main() {
463
466
  const checkAll = process.argv.includes('--check');
464
467
  const checkWhole = process.argv.includes('--check-whole');
465
468
  const checkBlock = process.argv.includes('--check-block');
469
+ // WRITE-side bucket selection, the sibling of the --check-* flags above (task
470
+ // 1002962). --whole-only regenerates the GITIGNORED docs/repo-map.md and leaves
471
+ // the TRACKED nested blocks alone.
472
+ //
473
+ // WHY a caller ever needs this: a dev box is a SPARSE checkout (box-access.js
474
+ // materializes only the claim's module cone). The block ordering is
475
+ // `b.refs - a.refs || name`, and `refs` counts references across the VISIBLE
476
+ // corpus — so a box with 7 of 20 modules computes different counts and emits a
477
+ // legitimately different block. Written into a tracked file that dirties the
478
+ // working tree, and box-source-fetch.sh's NEXT `git pull` aborts with "local
479
+ // changes would be overwritten" — a silent, permanent sync deadlock (one box sat
480
+ // 257 commits behind for three days). A box CONSUMES these blocks; they arrive
481
+ // correct with the pull, generated by CI from the whole tree. Only a full
482
+ // checkout may produce them.
483
+ const wholeOnly = process.argv.includes('--whole-only');
466
484
  const model = buildModel();
467
485
 
468
486
  if (process.argv.includes('--json')) {
@@ -478,8 +496,9 @@ function main() {
478
496
  const mapCur = fs.existsSync(mapPath) ? fs.readFileSync(mapPath, 'utf8') : '';
479
497
  if (!sameContent(mapCur, mapNext)) writes.push({ full: mapPath, content: mapNext, rel: 'docs/repo-map.md', bucket: 'whole' });
480
498
 
481
- // 2) nested CLAUDE.md generated blocks (tracked; the HARD-gated bucket)
482
- for (const dir of NESTED_DIRS) {
499
+ // 2) nested CLAUDE.md generated blocks (tracked; the HARD-gated bucket).
500
+ // Skipped entirely under --whole-only — see the flag's rationale above.
501
+ for (const dir of (wholeOnly ? [] : NESTED_DIRS)) {
483
502
  const docPath = path.join(REPO_ROOT, dir, 'CLAUDE.md');
484
503
  if (!fs.existsSync(docPath)) {
485
504
  console.error(`gen-repo-map: WARN nested doc missing, skipping: ${dir}/CLAUDE.md`);
@@ -25,6 +25,8 @@
25
25
  // node scripts/gds/gen-session-index.js --check # write nothing; exit 2 if EITHER bucket would change
26
26
  // node scripts/gds/gen-session-index.js --check-block # exit 2 only if the tracked CLAUDE.md §13 snippet drifts (CI gate)
27
27
  // node scripts/gds/gen-session-index.js --check-whole # exit 2 only if docs/session-log-index.md drifts
28
+ // node scripts/gds/gen-session-index.js --whole-only # WRITE the index only; never touch the tracked
29
+ // # CLAUDE.md snippet (sparse dev-box use; task 1002962)
28
30
  // docs/session-log-index.md is GITIGNORED + regenerated at deploy/box-fetch since ADR 0110 (task 1926).
29
31
  // node scripts/gds/gen-session-index.js --json # print the parsed entries as JSON (debug)
30
32
 
@@ -180,7 +182,15 @@ function main() {
180
182
  process.stdout.write(JSON.stringify(collectEntries(), null, 2) + '\n');
181
183
  return;
182
184
  }
183
- const { writes } = computeWrites();
185
+ // WRITE-side bucket selection — the sibling of the --check-* flags (task 1002962,
186
+ // the gen-repo-map --whole-only twin). A dev box is a SPARSE checkout, so writing
187
+ // the TRACKED bucket there dirties the tree and the next `git pull` in
188
+ // box-source-fetch.sh aborts on "local changes would be overwritten" — a silent,
189
+ // permanent sync deadlock. A box regenerates only the gitignored artifact; the
190
+ // tracked CLAUDE.md §13 snippet arrives with the pull, generated from the whole tree.
191
+ const wholeOnly = process.argv.includes('--whole-only');
192
+ const all = computeWrites().writes;
193
+ const writes = wholeOnly ? all.filter((w) => w.bucket === 'whole') : all;
184
194
  if (checkAll || checkWhole || checkBlock) {
185
195
  const wantBlock = checkAll || checkBlock;
186
196
  const wantWhole = checkAll || checkWhole;
@@ -1,9 +1,9 @@
1
1
  {
2
- "_doc": "The evergreen newcomer chores, grouped BY DISCIPLINE. Each discipline maps to a LIST of chore templates (was a single object before task 1488 — a discipline can now offer several first-builder chores so newcomers are not funnelled into one). The deterministic replenisher (scripts/gds/newcomer-floor.js) and the on-claim restock (modules/onboarding/newcomer-restock.js) stamp disposable claimable COPIES from each template; the TEMPLATE is never claimed and never ships. Each copy's source_ref is tmpl:<discipline>:<template_id>:<seq> (monotonic), so identical-title copies never collide with the dedup. Per-template `floor` sets that chore’s standing pool depth; if a template omits it, the discipline default in newcomer-floor.config.json applies. credits_reward, est_minutes and floor all live here (per chore). version_id is per-template so each chore lands on the correct track (engineer=internal GDS-V4, artist+ideator=product V2); it MUST point at an open (non-shipped) version — update it at version close. touches[] is intentionally empty so multiple same-discipline newcomers can claim copies concurrently; git-merge is the real collision detector. To ADD a chore: append an entry to the discipline's array. To CHANGE one: edit it here — no code change needed. Engineer offers a SAFE coding chore (add a unit test — touches only tests/, which auto-ships) and the docs-hygiene sweep (constrained to non-protected docs so a sub-Metic ship does not stall on the authority core).",
2
+ "_doc": "The evergreen newcomer chores, grouped BY DISCIPLINE. Each discipline maps to a LIST of chore templates (was a single object before task 1488 — a discipline can now offer several first-builder chores so newcomers are not funnelled into one). The deterministic replenisher (scripts/gds/newcomer-floor.js) and the on-claim restock (modules/onboarding/newcomer-restock.js) stamp disposable claimable COPIES from each template; the TEMPLATE is never claimed and never ships. Each copy's source_ref is tmpl:<discipline>:<template_id>:<seq> (monotonic), so identical-title copies never collide with the dedup. Per-template `floor` sets that chore’s standing pool depth; if a template omits it, the discipline default in newcomer-floor.config.json applies. credits_reward, est_minutes and floor all live here (per chore). version_id is per-template so each chore lands on the correct track; it MUST point at an open (non-shipped) version — update it at version close, or the replenisher's open-version guard refuses to stamp and the floor silently stops refilling (task 1002958: the engineer pins still read the long-shipped GDS-V4 and artist+ideator read V2, a version this ladder never had, so NO discipline could restock). touches[] is intentionally empty so multiple same-discipline newcomers can claim copies concurrently; git-merge is the real collision detector. To ADD a chore: append an entry to the discipline's array. To CHANGE one: edit it here — no code change needed. Engineer offers a SAFE coding chore (add a unit test — touches only tests/, which auto-ships) and the docs-hygiene sweep (constrained to non-protected docs so a sub-Metic ship does not stall on the authority core).",
3
3
  "engineer": [
4
4
  {
5
5
  "template_id": "unit-test-pass",
6
- "version_id": "GDS-V4",
6
+ "version_id": "BONGOS-V1",
7
7
  "discipline": "engineer",
8
8
  "kind": "feature",
9
9
  "est_minutes": 45,
@@ -22,7 +22,7 @@
22
22
  },
23
23
  {
24
24
  "template_id": "docs-hygiene-pass",
25
- "version_id": "GDS-V4",
25
+ "version_id": "BONGOS-V1",
26
26
  "discipline": "engineer",
27
27
  "kind": "cleanup",
28
28
  "est_minutes": 40,
@@ -43,7 +43,7 @@
43
43
  "artist": [
44
44
  {
45
45
  "template_id": "asset-generate-pass",
46
- "version_id": "V2",
46
+ "version_id": "BONGOS-V1",
47
47
  "discipline": "artist",
48
48
  "kind": "feature",
49
49
  "est_minutes": 55,
@@ -64,7 +64,7 @@
64
64
  "ideator": [
65
65
  {
66
66
  "template_id": "idea-seed-pass",
67
- "version_id": "V2",
67
+ "version_id": "BONGOS-V1",
68
68
  "discipline": "ideator",
69
69
  "kind": "feature",
70
70
  "est_minutes": 45,
package/src/module-api.js CHANGED
@@ -731,8 +731,12 @@ const { validateOrRespond, LIMITS, parseId, asyncHandler, corsPublicGet, parsePa
731
731
  // landed since 1.19.150 with no explicit bump. run 31953827282. (task 1002620)
732
732
  // 1.19.152 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
733
733
  // landed since 1.19.151 with no explicit bump. run 31955923444. (task 1002620)
734
+ // 1.19.153 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
735
+ // landed since 1.19.152 with no explicit bump. run 31956560292. (task 1002620)
736
+ // 1.19.154 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
737
+ // landed since 1.19.153 with no explicit bump. run 31957052737. (task 1002620)
734
738
  // ---------------------------------------------------------------------------
735
- const CORE_VERSION = '1.19.152'; // CI auto-patch carrier (ADR 0161); see changelog above
739
+ const CORE_VERSION = '1.19.154'; // CI auto-patch carrier (ADR 0161); see changelog above
736
740
 
737
741
  // A namespaced logger so a module's log lines are attributable + consistent.
738
742
  // Usage: const log = api.logger('dev-box'); log.info('mounted');
@@ -2,7 +2,7 @@
2
2
  import assert from 'node:assert/strict';
3
3
  import { test } from 'node:test';
4
4
  import { execFileSync } from 'node:child_process';
5
- import { readFileSync } from 'node:fs';
5
+ import { readFileSync, writeFileSync } from 'node:fs';
6
6
  import { createRequire } from 'node:module';
7
7
  import { fileURLToPath } from 'node:url';
8
8
  import path from 'node:path';
@@ -94,3 +94,42 @@ test('extractor parses functions, classes, arrow consts, and module.exports', ()
94
94
  const apiCall = model.allSyms.find((s) => s.name === 'apiCall' && s.file === 'scripts/gds/cli-lib.js');
95
95
  assert.ok(apiCall && apiCall.exported && apiCall.kind === 'fn', 'exported arrow/fn const detected with export flag');
96
96
  });
97
+
98
+ test('--whole-only never writes a TRACKED nested block (the sparse-box deadlock guard, task 1002962)', () => {
99
+ // A dev box is a SPARSE checkout — box-access.js materializes only the claim's
100
+ // module cone. The block ordering is `b.refs - a.refs || name` and `refs` counts
101
+ // references across the VISIBLE corpus, so a box with 7 of 20 modules emits a
102
+ // legitimately different block. box-source-fetch.sh used to write it, dirtying
103
+ // tracked files, and the NEXT `git pull` aborted on "local changes would be
104
+ // overwritten" — a silent permanent sync deadlock (one box sat 257 commits behind
105
+ // for three days). A box CONSUMES these blocks; only a full checkout may write them.
106
+ //
107
+ // Asserted on CONTENT, not on the log line: dirty a tracked block, run --whole-only,
108
+ // and require the block to come back byte-identical. A regression that re-enabled the
109
+ // bucket would rewrite it and fail here even if the summary line still looked right.
110
+ const tracked = path.join(ROOT, 'scripts', 'gds', 'CLAUDE.md');
111
+ const pristine = readFileSync(tracked, 'utf8');
112
+ const drifted = `${pristine}\n<!-- simulated sparse-checkout drift -->\n`;
113
+ writeFileSync(tracked, drifted);
114
+ try {
115
+ const r = run(['--whole-only']);
116
+ assert.equal(r.code, 0, `--whole-only should exit 0, got ${r.code} ${r.stderr || ''}`);
117
+ assert.equal(
118
+ readFileSync(tracked, 'utf8'),
119
+ drifted,
120
+ '--whole-only rewrote a tracked nested block — this is the deadlock that stranded a box 257 commits behind',
121
+ );
122
+ assert.ok(!r.stdout.includes('CLAUDE.md'), `--whole-only must not report a nested-doc write; got: ${r.stdout.trim()}`);
123
+ } finally {
124
+ writeFileSync(tracked, pristine);
125
+ }
126
+ });
127
+
128
+ test('the default (no-flag) run still owns BOTH buckets', () => {
129
+ // --whole-only must be strictly opt-in: CI and a full-checkout dev run keep
130
+ // regenerating the tracked blocks, which is what makes them trustworthy in git.
131
+ const src = readFileSync(GEN, 'utf8');
132
+ assert.match(src, /wholeOnly \? \[\] : NESTED_DIRS/, 'bucket skip should be gated on the flag, not unconditional');
133
+ // and on a clean tree the tracked bucket is genuinely current
134
+ assert.equal(run(['--check-block']).code, 0, 'tracked blocks must be current on a clean checkout');
135
+ });