@kungfu-tech/buildchain 4.0.1-alpha.4 → 4.0.1-alpha.6
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/actions/release-tail/README.md +8 -0
- package/architecture/decisions/0002-next-development-transition.md +101 -0
- package/architecture/internal-capabilities.json +117 -8
- package/architecture/maintainability-policy.json +38 -20
- package/architecture/release-tail-contract-inventory.json +5 -2
- package/architecture/v3-core-mechanism-inventory.json +89 -0
- package/architecture/v4-adopter-delivery-parity.json +32 -5
- package/architecture/v4-capability-state-machine-manifest.json +73 -0
- package/architecture/v4-compatibility-facts-parity.json +77 -0
- package/architecture/v4-next-development-parity.json +192 -0
- package/architecture/v4-publication-rehearsal-parity.json +84 -0
- package/architecture/v4-release-train-parity.json +1 -0
- package/architecture/v4-tail-reseal-parity.json +150 -0
- package/bin/buildchain.mjs +23 -2
- package/bin/internal/adopter-delivery-cli.mjs +70 -0
- package/bin/internal/command-registry.mjs +3 -0
- package/bin/internal/compatibility-facts-cli.mjs +101 -0
- package/contracts/fixtures/next-development-transition-v1/anchored-manual-waiting.json +47 -0
- package/contracts/fixtures/next-development-transition-v1/semver-auto-planned.json +47 -0
- package/contracts/fixtures/next-development-transition-v1/version-model-cases.json +40 -0
- package/contracts/fixtures/v4-adopter-delivery-v1/archive-template.json +19 -0
- package/contracts/fixtures/v4-adopter-delivery-v1/bootstrap-positive.json +93 -0
- package/contracts/fixtures/v4-adopter-delivery-v1/gate-positive.json +29 -0
- package/contracts/fixtures/v4-adopter-delivery-v1/gate-unknown-selector.json +26 -0
- package/contracts/fixtures/v4-adopter-delivery-v1/offline-vectors.json +50 -0
- package/contracts/fixtures/v4-compatibility-facts-v1/shared.json +1129 -0
- package/contracts/fixtures/v4-floating-consumer-policy-v1/cases.json +7 -1
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/artifacts/product.bin +1 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/config/buildchain.toml +5 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/documents/release-activation.json +1 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/documents/signed-channel.json +1 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/evidence/qualification.json +1 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/manifests/candidate.json +5 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/candidate/manifests/release-passport.json +1 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/capsule.json +707 -0
- package/contracts/fixtures/v4-publication-rehearsal-v1/offline-vectors.json +27 -0
- package/contracts/fixtures/v4-tail-reseal-v1/valid.json +229 -0
- package/contracts/next-development-request-v1.schema.json +66 -0
- package/contracts/next-development-transition-v1.schema.json +292 -0
- package/contracts/v4-adopter-delivery-v1.schema.json +81 -0
- package/contracts/v4-compatibility-facts-v1.schema.json +230 -0
- package/contracts/v4-publication-rehearsal-capsule-v1.schema.json +233 -0
- package/contracts/v4-tail-reseal-v1.schema.json +276 -0
- package/dist/site/agent-index.json +4 -0
- package/dist/site/artifact-schemas.json +8 -0
- package/dist/site/buildchain-contract.json +1393 -28
- package/dist/site/buildchain-site.json +462 -27
- package/dist/site/capability-registry.json +17 -14
- package/dist/site/cli-registry.json +159 -1
- package/dist/site/kfd-claims.json +429 -15
- package/dist/site/kfd-upstream-aggregate.json +1 -1
- package/dist/site/manual-registry.json +52 -6
- package/dist/site/node-api-registry.json +13972 -9697
- package/dist/site/page-registry.json +428 -17
- package/dist/site/public-surface-audit.json +429 -11
- package/dist/site/publication-authority-registry.json +22 -4
- package/dist/site/publication-registry.json +4 -4
- package/dist/site/release-provenance.json +21 -0
- package/dist/site/schemas/release-tail-capabilities-v1.schema.json +199 -0
- package/dist/site/schemas/v4-adopter-delivery-v1.schema.json +81 -0
- package/dist/site/schemas/v4-compatibility-facts-v1.schema.json +230 -0
- package/dist/site/schemas/v4-publication-rehearsal-capsule-v1.schema.json +233 -0
- package/dist/site/site-manifest.json +34 -10
- package/dist/site/workflow-registry.json +121 -8
- package/docs/MAP.md +7 -2
- package/docs/cli-reference.md +193 -0
- package/docs/cli.md +8 -0
- package/docs/dev-alpha-candidate-patrol.md +8 -0
- package/docs/next-development-transition.md +118 -0
- package/docs/node-api-reference.md +448 -168
- package/docs/release-tail-provider-plane.md +30 -0
- package/docs/v4-adopter-delivery.md +133 -0
- package/docs/v4-compatibility-facts.md +91 -0
- package/docs/v4-publication-rehearsal.md +130 -0
- package/docs/v4-tail-reseal.md +73 -0
- package/docs/versioning.md +4 -3
- package/package.json +29 -6
- package/packages/core/adopter-delivery-passport.js +259 -0
- package/packages/core/adopter-delivery-vectors.js +158 -0
- package/packages/core/adopter-delivery-vectors.json +77 -0
- package/packages/core/buildchain-agent-manuals.js +3 -0
- package/packages/core/buildchain-compatibility-authority.js +336 -0
- package/packages/core/buildchain-compatibility-fact.js +394 -0
- package/packages/core/buildchain-compatibility-facts.json +217 -0
- package/packages/core/buildchain-compatibility-proof.js +566 -0
- package/packages/core/buildchain-config.js +84 -0
- package/packages/core/buildchain-contract.js +93 -141
- package/packages/core/buildchain-delivery-bootstrap.js +240 -0
- package/packages/core/buildchain-delivery-infrastructure.js +164 -0
- package/packages/core/buildchain-delivery-self-dogfood.js +395 -0
- package/packages/core/channel-candidate.js +8 -0
- package/packages/core/channel-promotion-baseline.js +55 -0
- package/packages/core/dev-alpha-candidate-selection.js +10 -2
- package/packages/core/dev-delivery-execution-transfer.js +21 -1
- package/packages/core/dev-delivery-process-boundary.js +19 -6
- package/packages/core/dev-delivery-provider-heartbeat.js +18 -6
- package/packages/core/kungfu-temporal-fact.js +557 -0
- package/packages/core/legacy-kfd-adopter-driver.js +167 -0
- package/packages/core/next-development-candidate-reservation.js +186 -0
- package/packages/core/next-development-controller.js +728 -0
- package/packages/core/next-development-projection.js +287 -0
- package/packages/core/next-development-transition.js +738 -0
- package/packages/core/paper-agent-entry.js +11 -5
- package/packages/core/paper.js +16 -5
- package/packages/core/published-delivery-authority.js +266 -0
- package/packages/core/release-passport.js +26 -8
- package/packages/core/v4-adopter-delivery-parity.js +3 -3
- package/packages/core/v4-adopter-delivery.js +359 -0
- package/packages/core/v4-canonical-contracts.js +5 -0
- package/packages/core/v4-floating-consumer-policy.js +29 -9
- package/packages/core/v4-publication-rehearsal-capsule.js +468 -0
- package/packages/core/v4-publication-rehearsal-provider-bindings.js +212 -0
- package/packages/core/v4-publication-rehearsal.js +481 -0
- package/packages/core/v4-tail-reseal-contract.js +26 -0
- package/packages/core/v4-tail-reseal-github.js +178 -0
- package/packages/core/v4-tail-reseal-receipt.js +225 -0
- package/packages/core/v4-tail-reseal.js +594 -0
- package/scripts/buildchain-cli-help.mjs +30 -0
- package/scripts/check-inventory.mjs +14 -3
- package/scripts/dev-alpha-candidate-patrol.mjs +22 -1
- package/scripts/dev-delivery-source-proof-replay.mjs +153 -0
- package/scripts/dev-delivery-source-proof-reuse.mjs +13 -97
- package/scripts/generate-next-development-guidance.mjs +49 -0
- package/scripts/generate-release-candidate-passport.mjs +152 -0
- package/scripts/generate-site-bundle.mjs +46 -3
- package/scripts/init-repo.mjs +22 -4
- package/scripts/next-development-self-dogfood-harness.mjs +460 -0
- package/scripts/next-development-self-dogfood.mjs +597 -0
- package/scripts/next-development-transition.mjs +47 -0
- package/scripts/release-tail.mjs +51 -3
- package/scripts/resume-from-candidate-run.mjs +545 -15
- package/scripts/site-capability-metadata.mjs +28 -0
- package/scripts/v4-consumer-policy.mjs +1 -5
- package/scripts/v4-publication-rehearsal-fixture.mjs +144 -0
- package/scripts/v4-tail-reseal-macos-rehearsal.mjs +134 -0
- package/scripts/v4-tail-reseal.mjs +416 -0
package/docs/cli-reference.md
CHANGED
|
@@ -22,6 +22,63 @@ ai_provenance:
|
|
|
22
22
|
|
|
23
23
|
Every listed help command is intercepted before dispatch, exits zero, and performs no command side effects.
|
|
24
24
|
|
|
25
|
+
## `adopter-delivery`
|
|
26
|
+
|
|
27
|
+
### `buildchain adopter-delivery`
|
|
28
|
+
|
|
29
|
+
- Help: `buildchain adopter-delivery --help`
|
|
30
|
+
- Canonical id: `adopter-delivery`
|
|
31
|
+
- Options: none declared
|
|
32
|
+
- Syntax:
|
|
33
|
+
|
|
34
|
+
```text
|
|
35
|
+
buildchain adopter-delivery
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
### `buildchain adopter-delivery archive`
|
|
39
|
+
|
|
40
|
+
- Help: `buildchain adopter-delivery archive --help`
|
|
41
|
+
- Canonical id: `adopter-delivery`
|
|
42
|
+
- Options: `--input`, `--output`
|
|
43
|
+
- Syntax:
|
|
44
|
+
|
|
45
|
+
```text
|
|
46
|
+
buildchain adopter-delivery archive --input <json-or-path> [--output <path>]
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### `buildchain adopter-delivery bootstrap`
|
|
50
|
+
|
|
51
|
+
- Help: `buildchain adopter-delivery bootstrap --help`
|
|
52
|
+
- Canonical id: `adopter-delivery`
|
|
53
|
+
- Options: `--input`, `--output`
|
|
54
|
+
- Syntax:
|
|
55
|
+
|
|
56
|
+
```text
|
|
57
|
+
buildchain adopter-delivery bootstrap --input <json-or-path> [--output <path>]
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### `buildchain adopter-delivery run`
|
|
61
|
+
|
|
62
|
+
- Help: `buildchain adopter-delivery run --help`
|
|
63
|
+
- Canonical id: `adopter-delivery`
|
|
64
|
+
- Options: `--input`, `--output`
|
|
65
|
+
- Syntax:
|
|
66
|
+
|
|
67
|
+
```text
|
|
68
|
+
buildchain adopter-delivery run --input <json-or-path> [--output <path>]
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
### `buildchain adopter-delivery verify`
|
|
72
|
+
|
|
73
|
+
- Help: `buildchain adopter-delivery verify --help`
|
|
74
|
+
- Canonical id: `adopter-delivery`
|
|
75
|
+
- Options: `--input`, `--output`, `--readback`
|
|
76
|
+
- Syntax:
|
|
77
|
+
|
|
78
|
+
```text
|
|
79
|
+
buildchain adopter-delivery verify --input <json-or-path> --readback <json-or-path> [--output <path>]
|
|
80
|
+
```
|
|
81
|
+
|
|
25
82
|
## `architecture`
|
|
26
83
|
|
|
27
84
|
### `buildchain architecture`
|
|
@@ -728,6 +785,50 @@ buildchain facts
|
|
|
728
785
|
buildchain facts aggregate [--cwd <dir>] [--product <id>] [--module-fact <file>]... [--artifact <path>]... [--output <file>] [--json]
|
|
729
786
|
```
|
|
730
787
|
|
|
788
|
+
### `buildchain facts compatibility project`
|
|
789
|
+
|
|
790
|
+
- Help: `buildchain facts compatibility project --help`
|
|
791
|
+
- Canonical id: `build-facts`
|
|
792
|
+
- Options: `--cwd`, `--json`, `--output`, `--registry`
|
|
793
|
+
- Syntax:
|
|
794
|
+
|
|
795
|
+
```text
|
|
796
|
+
buildchain facts compatibility project [--cwd <dir>] [--registry <json-or-path>] [--output <file>] [--json]
|
|
797
|
+
```
|
|
798
|
+
|
|
799
|
+
### `buildchain facts compatibility query`
|
|
800
|
+
|
|
801
|
+
- Help: `buildchain facts compatibility query --help`
|
|
802
|
+
- Canonical id: `build-facts`
|
|
803
|
+
- Options: `--cwd`, `--json`, `--query`, `--registry`
|
|
804
|
+
- Syntax:
|
|
805
|
+
|
|
806
|
+
```text
|
|
807
|
+
buildchain facts compatibility query --query <json-or-path> [--registry <json-or-path>] [--cwd <dir>] [--json]
|
|
808
|
+
```
|
|
809
|
+
|
|
810
|
+
### `buildchain facts compatibility query-template`
|
|
811
|
+
|
|
812
|
+
- Help: `buildchain facts compatibility query-template --help`
|
|
813
|
+
- Canonical id: `build-facts`
|
|
814
|
+
- Options: `--cwd`, `--fact-root`, `--json`, `--query-id`, `--registry`
|
|
815
|
+
- Syntax:
|
|
816
|
+
|
|
817
|
+
```text
|
|
818
|
+
buildchain facts compatibility query-template --fact-root <sha256:...> [--query-id <id>] [--registry <json-or-path>] [--cwd <dir>] [--json]
|
|
819
|
+
```
|
|
820
|
+
|
|
821
|
+
### `buildchain facts compatibility verify`
|
|
822
|
+
|
|
823
|
+
- Help: `buildchain facts compatibility verify --help`
|
|
824
|
+
- Canonical id: `build-facts`
|
|
825
|
+
- Options: `--cwd`, `--json`, `--registry`
|
|
826
|
+
- Syntax:
|
|
827
|
+
|
|
828
|
+
```text
|
|
829
|
+
buildchain facts compatibility verify [--cwd <dir>] [--registry <json-or-path>] [--json]
|
|
830
|
+
```
|
|
831
|
+
|
|
731
832
|
### `buildchain facts module`
|
|
732
833
|
|
|
733
834
|
- Help: `buildchain facts module --help`
|
|
@@ -1586,6 +1687,30 @@ buildchain log <info|warn|error> --event <name> [--phase <phase>] [--component <
|
|
|
1586
1687
|
buildchain mark --event <name> [--phase <phase>] [--component <name>] [--attribute key=value]... [--path <jsonl>] [--json]
|
|
1587
1688
|
```
|
|
1588
1689
|
|
|
1690
|
+
## `next-development`
|
|
1691
|
+
|
|
1692
|
+
### `buildchain next-development`
|
|
1693
|
+
|
|
1694
|
+
- Help: `buildchain next-development --help`
|
|
1695
|
+
- Canonical id: `next-development`
|
|
1696
|
+
- Options: none declared
|
|
1697
|
+
- Syntax:
|
|
1698
|
+
|
|
1699
|
+
```text
|
|
1700
|
+
buildchain next-development
|
|
1701
|
+
```
|
|
1702
|
+
|
|
1703
|
+
### `buildchain next-development materialize`
|
|
1704
|
+
|
|
1705
|
+
- Help: `buildchain next-development materialize --help`
|
|
1706
|
+
- Canonical id: `next-development`
|
|
1707
|
+
- Options: `--cwd`, `--input`, `--json`, `--output`, `--write`
|
|
1708
|
+
- Syntax:
|
|
1709
|
+
|
|
1710
|
+
```text
|
|
1711
|
+
buildchain next-development materialize --input <request.json> [--cwd <dir>] [--write] [--output <path>] [--json]
|
|
1712
|
+
```
|
|
1713
|
+
|
|
1589
1714
|
## `npm`
|
|
1590
1715
|
|
|
1591
1716
|
### `buildchain npm`
|
|
@@ -2178,6 +2303,17 @@ buildchain release-tail init --declaration <json-or-path> [--state <path>]
|
|
|
2178
2303
|
buildchain release-tail plan --declaration <json-or-path> [--output <path>]
|
|
2179
2304
|
```
|
|
2180
2305
|
|
|
2306
|
+
### `buildchain release-tail rehearse`
|
|
2307
|
+
|
|
2308
|
+
- Help: `buildchain release-tail rehearse --help`
|
|
2309
|
+
- Canonical id: `release-tail`
|
|
2310
|
+
- Options: `--candidate-root`, `--capsule`, `--evidence`, `--mode`, `--state`
|
|
2311
|
+
- Syntax:
|
|
2312
|
+
|
|
2313
|
+
```text
|
|
2314
|
+
buildchain release-tail rehearse --capsule <absolute-path> --candidate-root <absolute-path> --mode <simulate|replay> --state <absolute-path> --evidence <absolute-path>
|
|
2315
|
+
```
|
|
2316
|
+
|
|
2181
2317
|
### `buildchain release-tail status`
|
|
2182
2318
|
|
|
2183
2319
|
- Help: `buildchain release-tail status --help`
|
|
@@ -2237,6 +2373,63 @@ buildchain sample process-tree [--interval-ms <n>] [--label <name>] [--output <j
|
|
|
2237
2373
|
buildchain span --event <name> [--phase <phase>] [--component <name>] [--path <jsonl>] -- <command> [args...]
|
|
2238
2374
|
```
|
|
2239
2375
|
|
|
2376
|
+
## `tail-reseal`
|
|
2377
|
+
|
|
2378
|
+
### `buildchain tail-reseal`
|
|
2379
|
+
|
|
2380
|
+
- Help: `buildchain tail-reseal --help`
|
|
2381
|
+
- Canonical id: `tail-reseal`
|
|
2382
|
+
- Options: none declared
|
|
2383
|
+
- Syntax:
|
|
2384
|
+
|
|
2385
|
+
```text
|
|
2386
|
+
buildchain tail-reseal
|
|
2387
|
+
```
|
|
2388
|
+
|
|
2389
|
+
### `buildchain tail-reseal admit`
|
|
2390
|
+
|
|
2391
|
+
- Help: `buildchain tail-reseal admit --help`
|
|
2392
|
+
- Canonical id: `tail-reseal`
|
|
2393
|
+
- Options: `--output`, `--request`
|
|
2394
|
+
- Syntax:
|
|
2395
|
+
|
|
2396
|
+
```text
|
|
2397
|
+
buildchain tail-reseal admit --request <request.json> [--output <admission.json>]
|
|
2398
|
+
```
|
|
2399
|
+
|
|
2400
|
+
### `buildchain tail-reseal plan`
|
|
2401
|
+
|
|
2402
|
+
- Help: `buildchain tail-reseal plan --help`
|
|
2403
|
+
- Canonical id: `tail-reseal`
|
|
2404
|
+
- Options: `--output`, `--request`
|
|
2405
|
+
- Syntax:
|
|
2406
|
+
|
|
2407
|
+
```text
|
|
2408
|
+
buildchain tail-reseal plan --request <request.json> [--output <plan.json>]
|
|
2409
|
+
```
|
|
2410
|
+
|
|
2411
|
+
### `buildchain tail-reseal seal`
|
|
2412
|
+
|
|
2413
|
+
- Help: `buildchain tail-reseal seal --help`
|
|
2414
|
+
- Canonical id: `tail-reseal`
|
|
2415
|
+
- Options: `--output`, `--passport`, `--plan`, `--protected-readback-root`, `--readbacks`, `--request`
|
|
2416
|
+
- Syntax:
|
|
2417
|
+
|
|
2418
|
+
```text
|
|
2419
|
+
buildchain tail-reseal seal --request <request.json> --plan <plan.json> --readbacks <dir> --passport <passport.json> --protected-readback-root <sha256:...> [--output <receipt.json>]
|
|
2420
|
+
```
|
|
2421
|
+
|
|
2422
|
+
### `buildchain tail-reseal verify-platform`
|
|
2423
|
+
|
|
2424
|
+
- Help: `buildchain tail-reseal verify-platform --help`
|
|
2425
|
+
- Canonical id: `tail-reseal`
|
|
2426
|
+
- Options: `--artifact-root`, `--mode`, `--output`, `--platform`, `--provider-readback-root`, `--request`
|
|
2427
|
+
- Syntax:
|
|
2428
|
+
|
|
2429
|
+
```text
|
|
2430
|
+
buildchain tail-reseal verify-platform --request <request.json> --platform <id> [--artifact-root <dir>] [--mode retained|resealed] [--provider-readback-root <sha256:...>] [--output <readback.json>]
|
|
2431
|
+
```
|
|
2432
|
+
|
|
2240
2433
|
## `transaction`
|
|
2241
2434
|
|
|
2242
2435
|
### `buildchain transaction`
|
package/docs/cli.md
CHANGED
|
@@ -1033,6 +1033,14 @@ The command validates `package.json`, infers the exact release tag
|
|
|
1033
1033
|
`npm publish --dry-run --access public --tag <alpha|latest>` unless
|
|
1034
1034
|
`--skip-npm-publish-dry-run` is passed. It never performs a real publish.
|
|
1035
1035
|
|
|
1036
|
+
## V4 Adopter Delivery
|
|
1037
|
+
|
|
1038
|
+
`buildchain adopter-delivery` exposes the public v4 driver gate, exact
|
|
1039
|
+
readback, N-1 bootstrap lineage, and published archive loader. `run` emits a
|
|
1040
|
+
rooted non-authoritative readback, `verify` recomputes it, `bootstrap` binds the
|
|
1041
|
+
exact v3 authority and v4 base, and `archive` verifies public npm archive bytes
|
|
1042
|
+
and package identity. See [`v4-adopter-delivery.md`](v4-adopter-delivery.md).
|
|
1043
|
+
|
|
1036
1044
|
## npm Publish Gate
|
|
1037
1045
|
|
|
1038
1046
|
Buildchain's own npm package is published from
|
|
@@ -59,6 +59,14 @@ controller then compares the selected SHA to the exact Alpha head before it can
|
|
|
59
59
|
be eligible, so a bounded scan cannot turn a commit outside the promotion
|
|
60
60
|
ancestry into a candidate.
|
|
61
61
|
|
|
62
|
+
Generated next-development version preparation is not a product candidate. The
|
|
63
|
+
observer skips both the signed `chore(release): prepare ...` commit and its
|
|
64
|
+
two-parent integration commit. When later product work becomes qualified, the
|
|
65
|
+
nearest preparation becomes a reservation: Patrol reads every path changed by
|
|
66
|
+
that preparation at both exact SHAs and requires identical Git blob identities.
|
|
67
|
+
A missing or stale reserved path blocks selection before the Release Cut and
|
|
68
|
+
therefore before any heavy candidate build.
|
|
69
|
+
|
|
62
70
|
The decision is `kungfu-buildchain-channel-candidate-decision/v1`. It records the
|
|
63
71
|
source and target branches and SHAs, comparison distance, workflow paths, run
|
|
64
72
|
identities and attempts, completion times, URLs, policy, and a canonical decision
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
---
|
|
2
|
+
status: preview
|
|
3
|
+
period: ongoing
|
|
4
|
+
theme: next-development-transition
|
|
5
|
+
doc_type: generated-contract-guidance
|
|
6
|
+
source_level: generated-from-node-contract
|
|
7
|
+
confidence: high
|
|
8
|
+
sensitivity: public
|
|
9
|
+
evidence_grade: A
|
|
10
|
+
review_state: self-reviewed
|
|
11
|
+
last_reviewed: 2026-08-11
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
# Next-development Transition
|
|
15
|
+
|
|
16
|
+
This document is generated from
|
|
17
|
+
`packages/core/next-development-transition.js` and
|
|
18
|
+
`packages/core/next-development-controller.js` and
|
|
19
|
+
`packages/core/next-development-projection.js`. Edit those sources and run
|
|
20
|
+
`node scripts/generate-next-development-guidance.mjs`; direct edits fail the
|
|
21
|
+
projection drift check.
|
|
22
|
+
|
|
23
|
+
## Contract
|
|
24
|
+
|
|
25
|
+
- Contract: `kungfu-buildchain-next-development-transition/v1`
|
|
26
|
+
- Durable controller: `kungfu-buildchain-next-development-controller/v1`
|
|
27
|
+
- ADR: [ADR 0002](../architecture/decisions/0002-next-development-transition.md)
|
|
28
|
+
- States: `planned`, `waiting-anchor`, `materialized`, `pr-pending`, `merged`, `verified`
|
|
29
|
+
- Legal version models: `semver/auto` and `anchored/manual`
|
|
30
|
+
- Invariant: A completed Alpha remains successful and its refs remain immutable while the next-development transition is incomplete.
|
|
31
|
+
|
|
32
|
+
An Alpha publication is terminal success independently of this transition.
|
|
33
|
+
The idempotency key is a deterministic hash of the completed-Alpha root,
|
|
34
|
+
repository, legal model, and sorted declared paths. Incomplete Dev preparation
|
|
35
|
+
therefore cannot relabel Alpha N as failed, and replay cannot select a different
|
|
36
|
+
Alpha or path set.
|
|
37
|
+
|
|
38
|
+
## Durable controller
|
|
39
|
+
|
|
40
|
+
`scheduleNextDevelopmentController` atomically creates one child for the
|
|
41
|
+
repository and completed-Alpha root. Identical wakes reuse it. The store
|
|
42
|
+
boundary requires read, create-if-absent, and compare-and-swap operations; the
|
|
43
|
+
controller root fences every checkpoint. Materialization uses an operation key
|
|
44
|
+
derived from the child, exact current protected Dev SHA, and reviewed target,
|
|
45
|
+
so a fresh runner can recover an already-created commit instead of rebuilding
|
|
46
|
+
the Alpha candidate or depending on the original runner workspace.
|
|
47
|
+
|
|
48
|
+
Before opening the protected version PR, the controller reads Dev again. A
|
|
49
|
+
moved head makes the prepared attempt `superseded`; the following wake
|
|
50
|
+
regenerates only declared version material from that latest SHA. After merge,
|
|
51
|
+
`verified` remains unreachable until protected Dev readback contains the
|
|
52
|
+
prepared commit and its target version, source roots, and derived roots exactly
|
|
53
|
+
match the checkpoint. The executor surface contains no Alpha publication, tag,
|
|
54
|
+
release, or package operation.
|
|
55
|
+
|
|
56
|
+
Alpha finalization no longer treats a non-fast-forward Dev update as successful
|
|
57
|
+
bookkeeping. It requires an exact checkout of the current Dev head, regenerates
|
|
58
|
+
the declared version lifecycle there, and uses a non-force merge or reusable
|
|
59
|
+
protected version PR. Candidate Patrol ignores both the generated preparation
|
|
60
|
+
commit and its two-parent integration commit. Before a later product candidate
|
|
61
|
+
can settle, Patrol reads every prepared version path at the candidate SHA and
|
|
62
|
+
requires the exact reserved blob identities; missing or stale state blocks
|
|
63
|
+
before a Release Cut or heavy candidate build.
|
|
64
|
+
|
|
65
|
+
## Version models
|
|
66
|
+
|
|
67
|
+
`semver/auto` increments the Alpha sequence on the same semantic patch. For
|
|
68
|
+
example, completed `1.4.2-alpha.7` plans `1.4.2-alpha.8`. It must not accept an anchor or an
|
|
69
|
+
operator-selected target.
|
|
70
|
+
|
|
71
|
+
`anchored/manual` enters `waiting-anchor` until the caller provides both a
|
|
72
|
+
semantic target and the exact digest of the configured anchor manifest. The
|
|
73
|
+
adapter verifies the manifest already present in the checkout; it never invents
|
|
74
|
+
or edits upstream anchor facts. `semver/manual` and `anchored/auto` are
|
|
75
|
+
invalid.
|
|
76
|
+
|
|
77
|
+
## Public self-dogfood and adoption
|
|
78
|
+
|
|
79
|
+
`.github/workflows/v4-public-consumer-dogfood.yml` remains the exact thin
|
|
80
|
+
consumer of the public `v4-stage-capsule-canary.yml@v4-alpha` contract. Its
|
|
81
|
+
declared `lifecycle.verify` runs `pnpm run check`, so the same public path
|
|
82
|
+
executes pure recovery tests that inject a transient durable-state write
|
|
83
|
+
failure, restore the adapter operation on a fresh runner, supersede stale work
|
|
84
|
+
when protected Dev moves, preserve `pr-pending` during protected-PR delay, and
|
|
85
|
+
prove both legal version models. No caller-local qualification job, action,
|
|
86
|
+
or private self-dogfood route is added.
|
|
87
|
+
|
|
88
|
+
The existing dual-channel self-consumer separately retains exact hosted
|
|
89
|
+
`build.yml@v4-alpha` and `build.yml@v4` runtime evidence. Consumers adopt
|
|
90
|
+
the proved contract through the floating v4 coordinates; exact resolved SHAs
|
|
91
|
+
remain audit evidence and never become durable selectors.
|
|
92
|
+
|
|
93
|
+
## Local adapter
|
|
94
|
+
|
|
95
|
+
From a normal Buildchain checkout:
|
|
96
|
+
|
|
97
|
+
```sh
|
|
98
|
+
node scripts/next-development-transition.mjs materialize --cwd . --input <request.json>
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
The command prints a rooted plan and performs no write by default. `--write`
|
|
102
|
+
may change only regular, non-symlink source files listed by `version.files`
|
|
103
|
+
in the loaded Buildchain config. The rooted adapter contract separately names
|
|
104
|
+
`version.derived_files` as allowed changes, `version.manifest` as read-only,
|
|
105
|
+
`BUILDCHAIN_VERSION` as the target input, `lifecycle.version-state` as the
|
|
106
|
+
derived-material stage, and `lifecycle.verify` as the truth gate. The
|
|
107
|
+
reference writer fails closed when derived files exist because transaction
|
|
108
|
+
execution is outside this contract slice. It performs no Git operation, ref
|
|
109
|
+
update, network request, provider call, lifecycle command, or anchor edit.
|
|
110
|
+
|
|
111
|
+
Preparing development state creates no tag, Release, public package, or
|
|
112
|
+
candidate. Those public effects remain outside the local adapter contract.
|
|
113
|
+
|
|
114
|
+
The request schema is
|
|
115
|
+
`contracts/next-development-request-v1.schema.json`; the durable record schema
|
|
116
|
+
is `contracts/next-development-transition-v1.schema.json`. Positive and
|
|
117
|
+
negative examples live under
|
|
118
|
+
`contracts/fixtures/next-development-transition-v1/`.
|