@kungfu-tech/buildchain 2.8.8-alpha.0 → 2.8.8-alpha.2

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.
@@ -127,7 +127,7 @@
127
127
  "path": "docs/lifecycle-protocol.md",
128
128
  "plane": "use",
129
129
  "exists": true,
130
- "digest": "sha256:02e1be97935c0d9520ea22e8ef0dc61d9b860c347f07127074600cdca02713ce"
130
+ "digest": "sha256:4d1ab96137beea2497b838018dcce793081c09dbcbbfd8ed2123cc58749f95cb"
131
131
  },
132
132
  {
133
133
  "id": "reusable-build-surface",
@@ -135,7 +135,7 @@
135
135
  "path": "docs/reusable-build-surface.md",
136
136
  "plane": "use",
137
137
  "exists": true,
138
- "digest": "sha256:8c3e7a5e099c8eb0715bb6f58af90d261f8cb83d384f3281b8763f340277582b"
138
+ "digest": "sha256:aae753c7fcf4bcb13c08af7b31cc83d898d36e41248b5f710ecee61035de3e8e"
139
139
  },
140
140
  {
141
141
  "id": "publish-transaction",
@@ -143,7 +143,7 @@
143
143
  "path": "docs/publish-transaction.md",
144
144
  "plane": "verify",
145
145
  "exists": true,
146
- "digest": "sha256:dd45cf98f0847e3968f150a09bed84aa1f59cb2687ac988e9519f08dc9c91877"
146
+ "digest": "sha256:d4758e222935f595f7d8a73fe2c33383898c0f760c5e5051c4f772db06491e7c"
147
147
  },
148
148
  {
149
149
  "id": "release-governance",
@@ -151,7 +151,7 @@
151
151
  "path": "docs/release-governance.md",
152
152
  "plane": "why",
153
153
  "exists": true,
154
- "digest": "sha256:c7348c64e83ea1d154955e2fc0f7318a1c5582a3dfa6bdc5728958ddb418e92d"
154
+ "digest": "sha256:53c969c38ede9c68e279ca191f2d5661e1d943225d7faa798179569670434ef9"
155
155
  },
156
156
  {
157
157
  "id": "release-flow",
@@ -244,11 +244,13 @@ version-state files changed. This prevents verification from quietly adding
244
244
  extra source changes to the release commit.
245
245
 
246
246
  On protected alpha and release branches, the generated version-state commit is
247
- merged through a normal pull request. This keeps review requirements,
248
- conversation resolution, strict status checks, and admin enforcement intact.
249
- After that PR lands, Buildchain verifies that the version-state PR changed only
250
- declared version files from the legal channel-promotion parent before it moves
251
- tags.
247
+ applied by the promotion automation after the reviewed channel PR has merged.
248
+ Buildchain keeps review requirements, conversation resolution, strict status
249
+ checks, and admin enforcement for human channel changes, but adds the
250
+ authenticated promotion token user or app to the managed bypass allowlist for
251
+ generated release bookkeeping. If the direct generated update is rejected,
252
+ promotion fails with a token/protection diagnostic instead of asking humans to
253
+ review a post-publish version-state PR.
252
254
 
253
255
  For `version.strategy = "anchored"` with `version.next = "manual"`, release
254
256
  promotion does not generate a Buildchain-owned version-state commit. In that
@@ -285,18 +285,22 @@ When publish transactions are enabled, promotion order is:
285
285
  7. move floating tags and channel refs;
286
286
  8. mark the transaction `complete`.
287
287
 
288
- If protected branches require a generated version-state PR, the transaction can
289
- stop in `finalizing` and output `finalization-needed=true`. A later run can
290
- resume from the same transaction state and complete ref movement without
291
- republishing matching artifacts.
288
+ If protected branch finalization is interrupted after publish evidence is
289
+ valid, the transaction can stop in `finalizing` and output
290
+ `finalization-needed=true`. A later run resumes from the same transaction state
291
+ and completes ref movement without republishing matching artifacts. New
292
+ Buildchain-managed promotions must finish generated version-state bookkeeping
293
+ with the promotion token directly; they must not require a post-publish human
294
+ PR.
292
295
 
293
296
  If finalization fails after an exact Git tag, a channel branch, or dev/alpha
294
297
  sync ref has already moved, the next run reads the durable `finalizing` state
295
298
  and continues from the recorded transaction. The current workflow SHA may be a
296
- version-state merge commit that contains or corresponds to the transaction's
297
- `release_material_sha`; it does not have to equal the original `source_sha` or
298
- the transaction `release_sha`. Exact tags are accepted when they already point
299
- at the transaction release/material SHA or the finalized channel head. Floating
299
+ generated version-state commit, or a historical version-state merge commit, that
300
+ contains or corresponds to the transaction's `release_material_sha`; it does not
301
+ have to equal the original `source_sha` or the transaction `release_sha`. Exact
302
+ tags are accepted when they already point at the transaction release/material
303
+ SHA or the finalized channel head. Floating
300
304
  channel tags and dev/alpha refs are then retried idempotently, and the
301
305
  transaction is marked `complete` only after those public refs are consistent.
302
306
  Writing `complete` clears any stale `failure` value from earlier attempts, so
@@ -25,7 +25,9 @@ If any one of these facts is updated by hand, the system can split:
25
25
  - an alpha can be promoted to production even though the release tree is not the
26
26
  same tree that was tested;
27
27
  - a protected branch merge can succeed while the follow-up version commit is
28
- missing.
28
+ missing, or a flow-internal generated `dev`/`alpha`/`release` ref update can
29
+ fail after publish because the automation identity was not declared in the
30
+ branch-protection review bypass allowance.
29
31
 
30
32
  The older ABV workflow addressed this by letting GitHub PRs drive release
31
33
  state. Buildchain keeps that choice because it makes release intent reviewable,
@@ -146,17 +148,20 @@ Buildchain then:
146
148
  This keeps the test channel self-describing. If a consumer checks out
147
149
  `v2.0-alpha`, the manifests and exact alpha tag agree.
148
150
 
149
- If `dev/vX/vX.Y` has already advanced while the generated alpha version-state PR
150
- was under review, Buildchain records `skipped-non-fast-forward` for the dev sync
151
- and still completes the exact and floating alpha tags for the reviewed alpha
152
- commit. Later dev changes must go through their own dev-to-alpha promotion
153
- instead of rewinding dev.
154
-
155
- If alpha finalization is resumed after the version-state PR is merged,
156
- Buildchain accepts the current alpha head as a merge commit that contains the
157
- recorded release material. An already-created exact alpha tag may point at the
158
- transaction release/material SHA or at the finalized alpha head; missing
159
- floating alpha tags are retried before the transaction becomes `complete`.
151
+ If `dev/vX/vX.Y` has already advanced before generated alpha version-state
152
+ bookkeeping can sync back, Buildchain records `skipped-non-fast-forward` for the
153
+ dev sync and still completes the exact and floating alpha tags for the reviewed
154
+ alpha commit. Later dev changes must go through their own dev-to-alpha
155
+ promotion instead of rewinding dev. The normal path is direct: after alpha
156
+ merges, Buildchain applies the generated version-state commit to alpha and then
157
+ fast-forwards dev to the same commit without a human version-state PR.
158
+
159
+ If alpha finalization is resumed after generated version-state bookkeeping was
160
+ partially applied, Buildchain accepts the current alpha head as the generated
161
+ commit, or as a historical merge commit that contains the recorded release
162
+ material. An already-created exact alpha tag may point at the transaction
163
+ release/material SHA or at the finalized alpha head; missing floating alpha
164
+ tags are retried before the transaction becomes `complete`.
160
165
 
161
166
  ## Release Semantics
162
167
 
@@ -186,11 +191,12 @@ The production channel and the test channel therefore intentionally diverge
186
191
  after release: production stays on the release commit, while alpha/dev continue
187
192
  at the next prerelease commit.
188
193
 
189
- If release finalization is resumed after the version-state PR is merged,
190
- Buildchain applies the same recovery rule: the current release head may be a
191
- merge commit that contains the recorded release material, existing exact tags
192
- and alpha/dev refs are accepted when they match the transaction, and missing
193
- floating `vX.Y` or `vX` tags are retried idempotently before completion.
194
+ If release finalization is resumed after generated version-state bookkeeping was
195
+ partially applied, Buildchain applies the same recovery rule: the current
196
+ release head may be the generated commit, or a historical merge commit that
197
+ contains the recorded release material, existing exact tags and alpha/dev refs
198
+ are accepted when they match the transaction, and missing floating `vX.Y` or
199
+ `vX` tags are retried idempotently before completion.
194
200
 
195
201
  ## Major Gate Semantics
196
202
 
@@ -393,12 +399,26 @@ The verify stage runs after generated version-state changes are applied locally
393
399
  and before any release refs move. If `verification-command` is passed directly
394
400
  to the action, that explicit command overrides `lifecycle.verify`.
395
401
 
396
- Protected release-line branches keep their normal review gate. When generated
397
- version state would move a protected alpha or release branch, Buildchain creates
398
- a version-state PR instead of bypassing branch protection. After that PR is
399
- reviewed, checked, and merged, the next promotion run verifies that only
400
- declared version-state files changed from the legally merged source parent, then
401
- moves the exact and floating tags.
402
+ Protected release-line branches keep their normal human review gate. Managed
403
+ `dev/vN/vN.M`, `alpha/vN/vN.M`, and `release/vN/vN.M` branches are configured
404
+ with one required approving review, strict GitHub Actions checks, administrator
405
+ enforcement, conversation resolution, no force pushes, and no deletions. The
406
+ reusable `release-candidate-promote.yml` wrapper defaults
407
+ `branch-protection-bypass-apps` to `github-actions`, which lets the workflow's
408
+ automation identity apply generated version-state or post-publish channel
409
+ bookkeeping after the reviewed channel PR has merged. Direct
410
+ `promote-buildchain-ref` callers must opt into the same controlled bypass with
411
+ `branch-protection-bypass-apps`, `branch-protection-bypass-users`, or
412
+ `branch-protection-bypass-teams`; the action also adds the current promotion
413
+ token's authenticated user or app to the managed bypass allowlist. If direct
414
+ generated bookkeeping is still rejected, Buildchain fails with a
415
+ token/protection diagnostic instead of creating a post-publish PR. Buildchain's
416
+ own promotion workflow reads `BUILDCHAIN_PROMOTION_BYPASS_APPS`,
417
+ `BUILDCHAIN_PROMOTION_BYPASS_USERS`, and
418
+ `BUILDCHAIN_PROMOTION_BYPASS_TEAMS` repository variables so the declared bypass
419
+ identity can match the actual `BUILDCHAIN_PROMOTION_TOKEN` actor, but consumers
420
+ do not need to duplicate that actor manually when the token identity is
421
+ discoverable.
402
422
 
403
423
  ## What This Guarantees
404
424
 
@@ -414,6 +434,9 @@ When the loop succeeds, maintainers and consumers can rely on these facts:
414
434
  - version manifests match the tag visible from the same commit;
415
435
  - production releases are derived from the alpha tree that was tested;
416
436
  - manual non-dry-run promotion cannot bypass PR review and verification;
437
+ - flow-internal automation bypasses apply only to declared GitHub Apps, users,
438
+ or teams on Buildchain-managed channel branch protection, while one-review
439
+ protection remains enforced for humans;
417
440
  - admin users cannot make a channel promotion valid by temporarily bypassing
418
441
  branch protection.
419
442
 
@@ -510,9 +510,14 @@ calls `actions/promote-buildchain-ref` with
510
510
  `require-publish-source-lock: "true"`. The wrapper passes the created
511
511
  `publish-gate/*` ref, target SHA, and `locked=true` into the promote action, so
512
512
  floating `@v2` consumers receive publish-side source-lock drift protection by
513
- default. It does not call `.build.yml`, does not create a matrix, and must fail
514
- before publish if the RC evidence, payload set, or source-lock ref is missing or
515
- ambiguous.
513
+ default. It also defaults `branch-protection-bypass-apps` to `github-actions`
514
+ so the workflow automation can apply generated version-state and channel
515
+ bookkeeping on protected `dev`/`alpha`/`release` branches after the reviewed
516
+ channel PR has merged; consumers using a different promotion identity can pass
517
+ `branch-protection-bypass-users`, `branch-protection-bypass-teams`, or a
518
+ different app slug declaratively. It does not call `.build.yml`, does not create
519
+ a matrix, and must fail before publish if the RC evidence, payload set, or
520
+ source-lock ref is missing or ambiguous.
516
521
 
517
522
  ```yaml
518
523
  jobs:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kungfu-tech/buildchain",
3
- "version": "2.8.8-alpha.0",
3
+ "version": "2.8.8-alpha.2",
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",