@kungfu-tech/buildchain 2.14.14 → 2.14.15-alpha.1

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.
@@ -4,7 +4,7 @@
4
4
  "product": {
5
5
  "name": "Buildchain",
6
6
  "package": "@kungfu-tech/buildchain",
7
- "version": "2.14.14",
7
+ "version": "2.14.15-alpha.1",
8
8
  "repository": "https://github.com/kungfu-systems/buildchain"
9
9
  },
10
10
  "majorLine": "v2",
@@ -604,7 +604,7 @@
604
604
  "agents can discover supported Node APIs without importing internal file paths"
605
605
  ],
606
606
  "breakingDigest": "sha256:48f925608d3e2131d90936b07dc2a30341204cae3e6e785c0f77d61ad755c945",
607
- "auditDigest": "sha256:3749e514599db7f4fe7ce8525c878010f556d2e6ea4f557eaad4a1bd94cf9ff7"
607
+ "auditDigest": "sha256:c026509d1fde0a1828ea7d8691f4dfc1d14686ae92a140f3d2350252699d70b3"
608
608
  },
609
609
  {
610
610
  "contractVersion": 1,
@@ -2913,5 +2913,5 @@
2913
2913
  }
2914
2914
  ],
2915
2915
  "compatibilityDigest": "sha256:cdf588422ec6b460bd6f631400efa6e361a045e052c8967d6c50fadd7aa4dd90",
2916
- "contractDigest": "sha256:05bca17e5d2a356660e5d1b76d40c023acd8b84d377f447339b77a63d594f8d7"
2916
+ "contractDigest": "sha256:98bf00165b325017f883bd55313ba1e6903654d591fd45adc35a9557fc422b82"
2917
2917
  }
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "contract": "kungfu-buildchain-site-bundle",
4
- "generatedAt": "2026-07-22T07:51:29.217Z",
5
- "publishedAt": "2026-07-22T07:51:29.217Z",
4
+ "generatedAt": "2026-07-22T09:24:49.017Z",
5
+ "publishedAt": "2026-07-22T09:24:49.017Z",
6
6
  "reproducible": true,
7
7
  "timestampPolicy": "ci-injected",
8
8
  "deterministicInputs": [
@@ -19,7 +19,7 @@
19
19
  "declared Buildchain surface manifest contract"
20
20
  ],
21
21
  "sourceDateEpoch": "0",
22
- "sourceRevision": "d7d1be6ace7aa6a342abbe8dc78b358534ff6b73",
22
+ "sourceRevision": "120948c0c71fa8659baaee95ace133acd6b14824",
23
23
  "timestampPolicyDetails": {
24
24
  "contract": "kungfu-buildchain-surface-timestamp-policy",
25
25
  "timestampFields": [
@@ -37,7 +37,7 @@
37
37
  },
38
38
  "package": {
39
39
  "name": "@kungfu-tech/buildchain",
40
- "version": "2.14.14",
40
+ "version": "2.14.15-alpha.1",
41
41
  "versionSource": "package.json#version"
42
42
  },
43
43
  "source": {
@@ -4,7 +4,7 @@
4
4
  "product": {
5
5
  "id": "kungfu-tech-buildchain",
6
6
  "name": "@kungfu-tech/buildchain",
7
- "version": "2.14.14",
7
+ "version": "2.14.15-alpha.1",
8
8
  "repository": "https://github.com/kungfu-systems/buildchain"
9
9
  },
10
10
  "source": {
@@ -112,7 +112,7 @@
112
112
  "specifier": "@kungfu-tech/buildchain/controller-evidence",
113
113
  "export": "./controller-evidence",
114
114
  "target": "./packages/core/controller-evidence.js",
115
- "digest": "sha256:3767d8dce1a18e610d4d1dcad3ef5e5c457d97f01769c9961cb45eb4d682ce59",
115
+ "digest": "sha256:c061ed32e02713fd99ffd291ee8ed4a4dba563265ee530deef4b37197cbb65e6",
116
116
  "summary": "Project-independent controller descriptors, source/runtime-bound plans, receipts, aggregates, and validation APIs.",
117
117
  "capabilityGroup": "reusable-build",
118
118
  "audience": [
@@ -177,7 +177,7 @@
177
177
  "specifier": "@kungfu-tech/buildchain/kfd-agent-hub",
178
178
  "export": "./kfd-agent-hub",
179
179
  "target": "./packages/core/kfd-agent-hub.js",
180
- "digest": "sha256:b301acb17af17f462af75f086f506bb529d2456647bfdbd78182852a413f5671",
180
+ "digest": "sha256:0221784b744fb2a0da02b95ed02b642b7456df2b8c2d8fb818aaa7e8a9a2deb1",
181
181
  "summary": "Declarative Agent Hub adapter inspection, fixed-suite execution, exact KFD cut locking, and agent explanation APIs.",
182
182
  "capabilityGroup": "kfd-trust",
183
183
  "audience": [
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "contract": "kungfu-buildchain-publication-release-registry",
4
- "generatedAt": "2026-07-22T07:51:29.217Z",
5
- "publishedAt": "2026-07-22T07:51:29.217Z",
4
+ "generatedAt": "2026-07-22T09:24:49.017Z",
5
+ "publishedAt": "2026-07-22T09:24:49.017Z",
6
6
  "reproducible": true,
7
7
  "timestampPolicy": "ci-injected",
8
8
  "deterministicInputs": [
@@ -19,7 +19,7 @@
19
19
  "declared Buildchain surface manifest contract"
20
20
  ],
21
21
  "sourceDateEpoch": "0",
22
- "sourceRevision": "d7d1be6ace7aa6a342abbe8dc78b358534ff6b73",
22
+ "sourceRevision": "120948c0c71fa8659baaee95ace133acd6b14824",
23
23
  "timestampPolicyDetails": {
24
24
  "contract": "kungfu-buildchain-surface-timestamp-policy",
25
25
  "timestampFields": [
@@ -32,7 +32,7 @@
32
32
  },
33
33
  "package": {
34
34
  "name": "@kungfu-tech/buildchain",
35
- "version": "2.14.14",
35
+ "version": "2.14.15-alpha.1",
36
36
  "versionSource": "package.json#version"
37
37
  },
38
38
  "sourceKind": "package-site-bundle",
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "contract": "kungfu-buildchain-site-manifest",
4
- "generatedAt": "2026-07-22T07:51:29.217Z",
5
- "publishedAt": "2026-07-22T07:51:29.217Z",
4
+ "generatedAt": "2026-07-22T09:24:49.017Z",
5
+ "publishedAt": "2026-07-22T09:24:49.017Z",
6
6
  "reproducible": true,
7
7
  "timestampPolicy": "ci-injected",
8
8
  "deterministicInputs": [
@@ -19,7 +19,7 @@
19
19
  "declared Buildchain surface manifest contract"
20
20
  ],
21
21
  "sourceDateEpoch": "0",
22
- "sourceRevision": "d7d1be6ace7aa6a342abbe8dc78b358534ff6b73",
22
+ "sourceRevision": "120948c0c71fa8659baaee95ace133acd6b14824",
23
23
  "timestampPolicyDetails": {
24
24
  "contract": "kungfu-buildchain-surface-timestamp-policy",
25
25
  "timestampFields": [
@@ -37,7 +37,7 @@
37
37
  },
38
38
  "package": {
39
39
  "name": "@kungfu-tech/buildchain",
40
- "version": "2.14.14",
40
+ "version": "2.14.15-alpha.1",
41
41
  "versionSource": "package.json#version"
42
42
  },
43
43
  "entrypoint": "buildchain-site.json",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kungfu-tech/buildchain",
3
- "version": "2.14.14",
3
+ "version": "2.14.15-alpha.1",
4
4
  "private": false,
5
5
  "description": "Buildchain Release Passport, release governance, CLI toolkit, and site facts.",
6
6
  "repository": "https://github.com/kungfu-systems/buildchain",
@@ -391,7 +391,7 @@ export function createControllerReceipt({ plan, stages = [], evidence = [], reas
391
391
  stages: normalizedStages,
392
392
  evidence: normalizedEvidence,
393
393
  issues,
394
- ...(reason ? {
394
+ ...(status !== "passed" && reason ? {
395
395
  reason: {
396
396
  code: nonEmptyString(reason.code, "reason.code"),
397
397
  summary: nonEmptyString(reason.summary, "reason.summary"),
@@ -414,6 +414,7 @@ export function validateControllerReceipt(receipt, {
414
414
  if (receipt.contract !== BUILDCHAIN_CONTROLLER_EVIDENCE_CONTRACT) issues.push(`receipt contract must be ${BUILDCHAIN_CONTROLLER_EVIDENCE_CONTRACT}`);
415
415
  if (receipt.kind !== "receipt") issues.push("receipt kind must be receipt");
416
416
  if (receipt.digest !== digestDocument(receipt)) issues.push("receipt digest mismatch");
417
+ if (receipt.status === "passed" && receipt.reason) issues.push("passed controller receipt must not declare a failure reason");
417
418
  issues.push(...(receipt.issues || []));
418
419
  if (plan) {
419
420
  if (receipt.planDigest !== plan.digest) issues.push("receipt plan digest mismatch");
@@ -1,8 +1,8 @@
1
1
  import crypto from "node:crypto";
2
- import { spawnSync } from "node:child_process";
3
2
  import fs from "node:fs";
4
3
  import { createRequire } from "node:module";
5
4
  import path from "node:path";
5
+ import { spawnSyncCommand } from "./spawn-command.js";
6
6
 
7
7
  export const KFD_AGENT_HUB_DECLARATION = ".buildchain/kfd/agent-hub.json";
8
8
  export const KFD_AGENT_HUB_OUTPUT_DIR = ".buildchain/artifacts/kfd-agent-hub";
@@ -278,7 +278,7 @@ function inspectKfdCut(kfd) {
278
278
  }
279
279
 
280
280
  function defaultRun(command, args, { cwd }) {
281
- const result = spawnSync(command, args, { cwd, encoding: "utf8", env: process.env });
281
+ const result = spawnSyncCommand(command, args, { cwd, encoding: "utf8", env: process.env });
282
282
  return { status: result.status ?? 2, stdout: result.stdout || "", stderr: result.stderr || "", error: result.error };
283
283
  }
284
284
 
@@ -0,0 +1,26 @@
1
+ import { spawnSync } from "node:child_process";
2
+
3
+ const WINDOWS_CMD_SHIMS = new Set(["corepack", "npm", "npx", "pnpm", "yarn"]);
4
+
5
+ export function resolveSpawnCommand(command, platform = process.platform) {
6
+ if (platform !== "win32" || !WINDOWS_CMD_SHIMS.has(command)) {
7
+ return command;
8
+ }
9
+ return `${command}.cmd`;
10
+ }
11
+
12
+ export function usesShellForSpawnCommand(command, platform = process.platform) {
13
+ return platform === "win32" && WINDOWS_CMD_SHIMS.has(command);
14
+ }
15
+
16
+ export function spawnSyncCommand(
17
+ command,
18
+ args,
19
+ options = {},
20
+ { platform = process.platform, spawn = spawnSync } = {},
21
+ ) {
22
+ return spawn(resolveSpawnCommand(command, platform), args, {
23
+ ...options,
24
+ shell: options.shell ?? usesShellForSpawnCommand(command, platform),
25
+ });
26
+ }
@@ -6,6 +6,12 @@ import os from "node:os";
6
6
  import path from "node:path";
7
7
  import { pathToFileURL } from "node:url";
8
8
  import { createBuildchainLogger } from "../packages/core/logging.js";
9
+ import {
10
+ resolveSpawnCommand,
11
+ usesShellForSpawnCommand,
12
+ } from "../packages/core/spawn-command.js";
13
+
14
+ export { resolveSpawnCommand, usesShellForSpawnCommand };
9
15
 
10
16
  function readArg(name, fallback = "") {
11
17
  const index = process.argv.indexOf(`--${name}`);
@@ -42,22 +48,6 @@ function timed(logger, eventName, details, callback) {
42
48
  }
43
49
  }
44
50
 
45
- const WINDOWS_CMD_SHIMS = new Set(["corepack", "npm", "npx", "pnpm", "yarn"]);
46
-
47
- export function resolveSpawnCommand(command, platform = process.platform) {
48
- if (platform !== "win32") {
49
- return command;
50
- }
51
- if (!WINDOWS_CMD_SHIMS.has(command)) {
52
- return command;
53
- }
54
- return `${command}.cmd`;
55
- }
56
-
57
- export function usesShellForSpawnCommand(command, platform = process.platform) {
58
- return platform === "win32" && WINDOWS_CMD_SHIMS.has(command);
59
- }
60
-
61
51
  function run(command, args, options = {}) {
62
52
  const { logger, event = "process.run", phase = "process", attributes = {}, ...spawnOptions } = options;
63
53
  const resolvedCommand = resolveSpawnCommand(command);