@bongos/core 1.19.859 → 1.19.861

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.859",
6
- "core_contract": "1.19.859",
7
- "source_commit": "88f0482054c54e919261f2a12807d600816ed82a",
5
+ "core_version": "1.19.861",
6
+ "core_contract": "1.19.861",
7
+ "source_commit": "4e1d31227bc0a2db3534bfbaa9fedd102870074e",
8
8
  "source_ref": "HEAD",
9
- "built_at": "2026-09-17T22:12:12.572Z",
9
+ "built_at": "2026-09-17T22:42:20.133Z",
10
10
  "redaction": {
11
11
  "model": "docs-redacted+functional-verbatim",
12
12
  "docs_redacted": 498,
@@ -17,7 +17,7 @@
17
17
  "gate": "passed"
18
18
  },
19
19
  "file_count": 2804,
20
- "tree_sha256": "b78ad9f6f954e75b5baea41887323131be92e116c1966a2199cca319f8b0b875",
20
+ "tree_sha256": "49fc880b51d9733acfbdbedf53c6d696191648b163cb0e702bc44b1722384f41",
21
21
  "files": [
22
22
  {
23
23
  "path": ".claude/skills/ask-for-help/SKILL.md",
@@ -2592,7 +2592,7 @@
2592
2592
  {
2593
2593
  "path": "docs/module-api-changelog.md",
2594
2594
  "mode": "0000644",
2595
- "sha256": "1e68c4750a4f88d910f87d06d8f99acaabe7c8c0c393a3da8b94ecd9b3b32ca8"
2595
+ "sha256": "5ad4d4175cf1bdfd1fc4d58946722c87309a07ff9d6146658ae7bbe32a93af51"
2596
2596
  },
2597
2597
  {
2598
2598
  "path": "docs/modules-contract.md",
@@ -7917,12 +7917,12 @@
7917
7917
  {
7918
7918
  "path": "package-lock.json",
7919
7919
  "mode": "0000644",
7920
- "sha256": "2d544ea0fed5368d5c140a2e44b18b8265be912369bd47dcf78b5fcfaef6d739"
7920
+ "sha256": "a3caf19c193288a64f26ef67883b6924563861d286aaa8dc102826081692f66c"
7921
7921
  },
7922
7922
  {
7923
7923
  "path": "package.json",
7924
7924
  "mode": "0000644",
7925
- "sha256": "3aa07b12e96b6217ec805ae73ff8d535d1ac92c4c5d00d6074d8e92afd2672cb"
7925
+ "sha256": "321bdc4e8a5d0a857eb37f0bcb3410dc16bc50f32f3f9b9fec7e28e90991c10b"
7926
7926
  },
7927
7927
  {
7928
7928
  "path": "public-docs/index.html",
@@ -8387,7 +8387,7 @@
8387
8387
  {
8388
8388
  "path": "scripts/gds/doctor.js",
8389
8389
  "mode": "0000644",
8390
- "sha256": "eaae00a0124635c26f45b4f6620ed95e913a5c2140178fb85bd3f5020dab5d44"
8390
+ "sha256": "f690a26bac623e67d4d4a8d889c5f69b05a8afb98eda13309e73b45c9f5fbbaa"
8391
8391
  },
8392
8392
  {
8393
8393
  "path": "scripts/gds/enroll-control-plane.js",
@@ -9867,7 +9867,7 @@
9867
9867
  {
9868
9868
  "path": "src/module-api.js",
9869
9869
  "mode": "0000644",
9870
- "sha256": "6c6509130bcd722c09a1aca7f9b4f9bcd82200c2e47b9b68659d0b831ac606e5"
9870
+ "sha256": "e9b79cddc8f92f9cd1f7b1aa22ffd661af52a68f08f469f43879d1f9cf6df545"
9871
9871
  },
9872
9872
  {
9873
9873
  "path": "src/module-loader/catalog.js",
@@ -11027,7 +11027,7 @@
11027
11027
  {
11028
11028
  "path": "tests/doctor_hooks.mjs",
11029
11029
  "mode": "0000644",
11030
- "sha256": "89e05751271dd18b96a2319d624403353bdc710b2e8b5c0cf6181b125cd17b76"
11030
+ "sha256": "e07d380e22f833d9ecf48cafb546dbe75830b6b45f6a73625eca20ca385d0909"
11031
11031
  },
11032
11032
  {
11033
11033
  "path": "tests/edit_hints.mjs",
@@ -2192,5 +2192,9 @@ is load-bearing: the script throws rather than guess if it is missing, and
2192
2192
  landed since 1.19.857 with no explicit bump. run 35279781206. (task 1002620)
2193
2193
  1.19.859 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
2194
2194
  landed since 1.19.858 with no explicit bump. run 35280770718. (task 1002620)
2195
+ 1.19.860 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
2196
+ landed since 1.19.859 with no explicit bump. run 35281454119. (task 1002620)
2197
+ 1.19.861 — CI auto-patch (publish-on-merge, ADR 0161): carrier for merges
2198
+ landed since 1.19.860 with no explicit bump. run 35283293619. (task 1002620)
2195
2199
  ---------------------------------------------------------------------------
2196
2200
  ```
package/package-lock.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@bongos/core",
3
- "version": "1.19.859",
3
+ "version": "1.19.861",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "@bongos/core",
9
- "version": "1.19.859",
9
+ "version": "1.19.861",
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.859",
3
+ "version": "1.19.861",
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",
@@ -216,6 +216,41 @@ function classifyHooksState({ hooksPath, worktreeRoot, exists = fs.existsSync })
216
216
  return { status: 'ok', code: 'active', resolved, message: `core.hooksPath="${hooksPath}" → ${resolved} (exists)` };
217
217
  }
218
218
 
219
+ // The pre-commit verdict, extracted pure so it can be tested (the classifyHooksState
220
+ // precedent above, task 1002524).
221
+ //
222
+ // ABSENT IS NOT A FAULT (task 1003773). The core ships `.husky/pre-push` and
223
+ // `.husky/post-merge` and nothing else — `.husky/pre-commit` has never existed in git
224
+ // history, and install-git-hooks.js says outright that an instance MAY add one. Doctor
225
+ // used to warn unconditionally that the "secrets-guard hook will not fire", which asserts
226
+ // a live hole in the walls on every clean clone. That trains builders to skim this very
227
+ // section — the one carrying the REAL fault, an unset core.hooksPath that genuinely does
228
+ // disable pre-push. A false positive beside a true positive degrades the true one.
229
+ //
230
+ // Secrets are enforced by .claude/hooks/secret-gate.js and the CI secrets-scan in
231
+ // .github/workflows/main-audit.yml, neither of which the old warning mentioned.
232
+ //
233
+ // A pre-commit file that EXISTS but is not executable is still a real fault: someone
234
+ // installed a gate that silently does not run.
235
+ function classifyPreCommitState({ preCommitPath, present, executable }) {
236
+ if (!present) {
237
+ return {
238
+ status: 'ok',
239
+ code: 'absent-by-design',
240
+ message: 'no pre-commit hook — the core ships pre-push only, by design. '
241
+ + 'Secrets are enforced by .claude/hooks/secret-gate.js and the CI secrets-scan.',
242
+ };
243
+ }
244
+ if (!executable) {
245
+ return {
246
+ status: 'warn',
247
+ code: 'not-executable',
248
+ message: `pre-commit exists but is not executable: ${preCommitPath}`,
249
+ };
250
+ }
251
+ return { status: 'ok', code: 'active', message: 'pre-commit hook is executable.' };
252
+ }
253
+
219
254
  function checkGitPlumbing() {
220
255
  section('Git plumbing');
221
256
  const verdict = classifyHooksState({
@@ -226,16 +261,13 @@ function checkGitPlumbing() {
226
261
  report('git', verdict.message);
227
262
  if (verdict.status !== 'ok') return;
228
263
  const preCommit = path.join(verdict.resolved, 'pre-commit');
229
- if (!fs.existsSync(preCommit)) {
230
- warn('git', `No pre-commit file at ${preCommit} — secrets-guard hook will not fire.`);
231
- } else {
232
- try {
233
- fs.accessSync(preCommit, fs.constants.X_OK);
234
- ok('git', `pre-commit hook is executable.`);
235
- } catch (_) {
236
- warn('git', `pre-commit exists but is not executable: ${preCommit}`);
237
- }
264
+ const present = fs.existsSync(preCommit);
265
+ let executable = false;
266
+ if (present) {
267
+ try { fs.accessSync(preCommit, fs.constants.X_OK); executable = true; } catch (_) { executable = false; }
238
268
  }
269
+ const pre = classifyPreCommitState({ preCommitPath: preCommit, present, executable });
270
+ ({ ok, warn, fail }[pre.status])('git', pre.message);
239
271
  }
240
272
 
241
273
  // --------------------------------------------------------------------------
@@ -406,7 +438,7 @@ function checkRunnerDrift() {
406
438
  // --------------------------------------------------------------------------
407
439
  // Guarded so requiring this file for its pure helpers (tests/doctor_hooks.mjs)
408
440
  // does not run the checks, which shell out to git and hit the network.
409
- module.exports = { classifyHooksState, runnerDriftRows };
441
+ module.exports = { classifyHooksState, classifyPreCommitState, runnerDriftRows };
410
442
 
411
443
  if (require.main === module) (async () => {
412
444
  console.log(`${C.bold}GDS Doctor${C.reset} — local-machine health check`);
package/src/module-api.js CHANGED
@@ -71,7 +71,7 @@ const { responsibilityFor, ROLE_RESPONSIBILITIES } = require('./role-responsibil
71
71
  // there. scripts/gds/bump-version.js still rewrites the literal below; it appends
72
72
  // the entry to that file. Look for a version's history there, not here.
73
73
  // ---------------------------------------------------------------------------
74
- const CORE_VERSION = '1.19.859'; // CI auto-patch carrier (ADR 0161); changelog: docs/module-api-changelog.md
74
+ const CORE_VERSION = '1.19.861'; // CI auto-patch carrier (ADR 0161); changelog: docs/module-api-changelog.md
75
75
 
76
76
  // A namespaced logger so a module's log lines are attributable + consistent.
77
77
  // Usage: const log = api.logger('dev-box'); log.info('mounted');
@@ -25,7 +25,7 @@ import { createRequire } from 'node:module';
25
25
  import path from 'node:path';
26
26
 
27
27
  const require = createRequire(import.meta.url);
28
- const { classifyHooksState } = require('../scripts/gds/doctor.js');
28
+ const { classifyHooksState, classifyPreCommitState } = require('../scripts/gds/doctor.js');
29
29
 
30
30
  let passed = 0;
31
31
  let failed = 0;
@@ -137,5 +137,36 @@ test('every verdict carries a non-empty message', () => {
137
137
  });
138
138
 
139
139
  console.log('');
140
+ // ---- pre-commit verdict (task 1003773) -------------------------------------
141
+ //
142
+ // The core ships .husky/pre-push and .husky/post-merge only; .husky/pre-commit has
143
+ // never existed in git history. Doctor warned "secrets-guard hook will not fire" on
144
+ // every clean clone — asserting a live hole in the walls where there is none, in the
145
+ // same section that carries the real fault (an unset core.hooksPath). Absent is OK;
146
+ // present-but-not-executable is the case that IS a fault.
147
+
148
+ test('an ABSENT pre-commit is ok, not a warning — the core ships pre-push by design', () => {
149
+ const v = classifyPreCommitState({ preCommitPath: '/repo/.husky/pre-commit', present: false, executable: false });
150
+ assert.equal(v.status, 'ok', 'a clean clone must not be warned at');
151
+ assert.equal(v.code, 'absent-by-design');
152
+ assert.doesNotMatch(v.message, /will not fire/, 'must not assert a dead security gate');
153
+ // It must NAME what does enforce, or it is just a silenced warning.
154
+ assert.match(v.message, /secret-gate\.js/);
155
+ assert.match(v.message, /secrets-scan/);
156
+ });
157
+
158
+ test('a pre-commit that exists but is not executable is still a WARN', () => {
159
+ const v = classifyPreCommitState({ preCommitPath: '/repo/.husky/pre-commit', present: true, executable: false });
160
+ assert.equal(v.status, 'warn', 'an installed gate that cannot run is a real fault');
161
+ assert.equal(v.code, 'not-executable');
162
+ assert.match(v.message, /not executable/);
163
+ });
164
+
165
+ test('an executable pre-commit is ok', () => {
166
+ const v = classifyPreCommitState({ preCommitPath: '/repo/.husky/pre-commit', present: true, executable: true });
167
+ assert.equal(v.status, 'ok');
168
+ assert.equal(v.code, 'active');
169
+ });
170
+
140
171
  console.log(`${passed} passed, ${failed} failed`);
141
172
  process.exit(failed === 0 ? 0 : 1);