@kungfu-tech/buildchain 2.12.7-alpha.20 → 2.12.7-alpha.21

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.12.7-alpha.20",
7
+ "version": "2.12.7-alpha.21",
8
8
  "repository": "https://github.com/kungfu-systems/buildchain"
9
9
  },
10
10
  "majorLine": "v2",
@@ -2679,5 +2679,5 @@
2679
2679
  }
2680
2680
  ],
2681
2681
  "compatibilityDigest": "sha256:af162b86ab4506e9b5f1d3c59b41f3fd57fbad79ff4d749a7f12ff16460517f8",
2682
- "contractDigest": "sha256:4d9fa59bd60cb59e2b2a0158a603316251320123dec0d840dc2e678ec181b273"
2682
+ "contractDigest": "sha256:048014d9eac273cb507311984dda5030552741df29ed2177f0b9a347d932a423"
2683
2683
  }
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "contract": "kungfu-buildchain-site-bundle",
4
- "generatedAt": "2026-07-15T11:14:41.049Z",
5
- "publishedAt": "2026-07-15T11:14:41.049Z",
4
+ "generatedAt": "2026-07-15T12:26:57.218Z",
5
+ "publishedAt": "2026-07-15T12:26:57.218Z",
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": "ff6924b387efca463b7312eb7198416bfe39654d",
22
+ "sourceRevision": "97973413b7ba208df42a3ead28d2b80067a3ecc8",
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.12.7-alpha.20",
40
+ "version": "2.12.7-alpha.21",
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.12.7-alpha.20",
7
+ "version": "2.12.7-alpha.21",
8
8
  "repository": "https://github.com/kungfu-systems/buildchain"
9
9
  },
10
10
  "source": {
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": 1,
3
3
  "contract": "kungfu-buildchain-publication-release-registry",
4
- "generatedAt": "2026-07-15T11:14:41.049Z",
5
- "publishedAt": "2026-07-15T11:14:41.049Z",
4
+ "generatedAt": "2026-07-15T12:26:57.218Z",
5
+ "publishedAt": "2026-07-15T12:26:57.218Z",
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": "ff6924b387efca463b7312eb7198416bfe39654d",
22
+ "sourceRevision": "97973413b7ba208df42a3ead28d2b80067a3ecc8",
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.12.7-alpha.20",
35
+ "version": "2.12.7-alpha.21",
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-15T11:14:41.049Z",
5
- "publishedAt": "2026-07-15T11:14:41.049Z",
4
+ "generatedAt": "2026-07-15T12:26:57.218Z",
5
+ "publishedAt": "2026-07-15T12:26:57.218Z",
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": "ff6924b387efca463b7312eb7198416bfe39654d",
22
+ "sourceRevision": "97973413b7ba208df42a3ead28d2b80067a3ecc8",
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.12.7-alpha.20",
40
+ "version": "2.12.7-alpha.21",
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.12.7-alpha.20",
3
+ "version": "2.12.7-alpha.21",
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",
@@ -6,6 +6,7 @@ import path from "node:path";
6
6
  import { pathToFileURL } from "node:url";
7
7
 
8
8
  export const LOCKED_SOURCE_CHECKOUT_CONTRACT = "kungfu-buildchain-locked-source-checkout-cache";
9
+ export const ISOLATED_GIT_GLOBAL_CONFIG = process.platform === "win32" ? "NUL" : "/dev/null";
9
10
 
10
11
  const GIT_SHA_PATTERN = /^[0-9a-f]{40}$/i;
11
12
 
@@ -133,6 +134,24 @@ function githubAuthEnv(token = "") {
133
134
  };
134
135
  }
135
136
 
137
+ function isolatedGitFetchEnv(env = {}, targetPath) {
138
+ const configuredCount = Number.parseInt(env.GIT_CONFIG_COUNT || "0", 10);
139
+ const safeDirectoryIndex = Number.isInteger(configuredCount) && configuredCount >= 0
140
+ ? configuredCount
141
+ : 0;
142
+ return {
143
+ ...env,
144
+ // Runner-global URL rewrites are shared mutable state. A concurrent job
145
+ // may point the same repository URL at a different single-SHA bundle, so
146
+ // network fetches must not consult the account-level Git config.
147
+ GIT_CONFIG_GLOBAL: ISOLATED_GIT_GLOBAL_CONFIG,
148
+ GIT_CONFIG_NOSYSTEM: "1",
149
+ GIT_CONFIG_COUNT: String(safeDirectoryIndex + 1),
150
+ [`GIT_CONFIG_KEY_${safeDirectoryIndex}`]: "safe.directory",
151
+ [`GIT_CONFIG_VALUE_${safeDirectoryIndex}`]: path.resolve(targetPath),
152
+ };
153
+ }
154
+
136
155
  function markSafeDirectory(targetPath, timeoutMs) {
137
156
  try {
138
157
  git(["config", "--global", "--add", "safe.directory", path.resolve(targetPath)], {
@@ -206,6 +225,7 @@ export function fetchSourceCommit({
206
225
  runGit = git,
207
226
  containsCommit = hasCommit,
208
227
  }) {
228
+ const fetchEnv = isolatedGitFetchEnv(env, targetPath);
209
229
  try {
210
230
  runGit(["remote", "remove", remoteName], { cwd: targetPath, timeoutMs, stdio: "ignore" });
211
231
  } catch {
@@ -222,7 +242,7 @@ export function fetchSourceCommit({
222
242
  runGit(["fetch", "--no-tags", "--depth=1", remoteName, `+${fetchRef}:refs/buildchain/source-ref`], {
223
243
  cwd: targetPath,
224
244
  timeoutMs,
225
- env,
245
+ env: fetchEnv,
226
246
  });
227
247
  if (containsCommit(targetPath, sha, timeoutMs)) {
228
248
  return { selector: "ref", checkoutSha: sha };
@@ -252,7 +272,7 @@ export function fetchSourceCommit({
252
272
  runGit(["fetch", "--no-tags", "--depth=1", remoteName, `+${sha}:refs/buildchain/source`], {
253
273
  cwd: targetPath,
254
274
  timeoutMs,
255
- env,
275
+ env: fetchEnv,
256
276
  });
257
277
  if (!containsCommit(targetPath, sha, timeoutMs)) {
258
278
  throw new Error(`fetched ${fetchRef || sha}, but ${sha} is not available`);