codex-workflow-v2 2.0.0-alpha.6 → 2.0.0-alpha.6.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.
package/docs/decisions.md CHANGED
@@ -80,3 +80,7 @@ This document closes the requirement gaps identified during the V2 design review
80
80
  15. **Safe update preflight.** Dependency updates begin with a read-only preflight requiring
81
81
  a clean checkout, no running Step, and no active writer lease. It does not install,
82
82
  migrate, or mutate project state.
83
+ 16. **Claimed-C1 rescue is one guarded transition.** The alpha.6.1 backport may bypass only
84
+ the stale Knowledge binding that blocks one exact pending strict review. It requires the
85
+ original claimant actor and writer token, preserves the lease, rechecks clean completion
86
+ HEAD and C1 bindings, and never composes stale-lock repair with review.
package/docs/release.md CHANGED
@@ -31,3 +31,7 @@ Tag releases as `v<package-version>`. The tag workflow verifies the tag/package
31
31
  uses npm trusted publishing with public access. For a public GitHub repository and public
32
32
  package, npm trusted publishing generates provenance automatically. Publishing is never
33
33
  performed by local validation commands.
34
+
35
+ The `2.0.0-alpha.6.x` backport line publishes with the dedicated `backport-alpha6`
36
+ dist-tag (or by exact version). It must never move npm's `next` tag, which remains owned by
37
+ the alpha.7 line.
@@ -22,6 +22,46 @@ state schema. Совпадение `stateSchemaVersion` до и после об
22
22
  нужна. Для alpha.6 при `stateSchemaVersion: 2` применяется не migration, а sidecar-only
23
23
  adoption posture.
24
24
 
25
+ ## Исключение: claimed C1 strict-review deadlock в alpha.6
26
+
27
+ Не обновляйте dependency, если alpha.6 Task уже имеет `in_progress` Step с completion evidence,
28
+ pending strict review и stale Knowledge binding. Для такого состояния используйте внешний
29
+ точный runner `2.0.0-alpha.6.1`; сам проект до завершения recovery остаётся закреплён на
30
+ `2.0.0-alpha.6`.
31
+
32
+ Сначала выполните только `update rescue-preflight`. Продолжать разрешено исключительно при
33
+ `eligible=true` и одной exact action `update rescue-review`. Передайте returned Task ID, Step
34
+ ID, revision, claimant actor и исходный bound writer token. Не выводите token в чат и не
35
+ передавайте другому actor.
36
+
37
+ Recovery не требует и не допускает предварительный `locks repair`: alpha.6.1 проверяет token
38
+ сразу против существующего lease и C1 hash, затем сохраняет и heartbeat'ит тот же lease в
39
+ единственной guarded review-команде. Active и stale lease допустимы только при exact binding.
40
+ Неверный actor/token, dirty checkout, advanced HEAD, второй pending review
41
+ или посторонний lease блокируют переход без изменения Task state.
42
+
43
+ После successful review следуйте обычному `next`: reconcile/approve Knowledge Map, выполните
44
+ knowledge rebind, свежую authorization и завершите Task. Только на безопасной lifecycle-границе
45
+ запускайте обычное обновление dependency и gateway.
46
+
47
+ ## Исключение: signal_v4 после двух failed review в alpha.6
48
+
49
+ Если точный alpha.6 state уже дошёл до Task revision 14/status `ready`, `STEP-001` имеет два
50
+ distinct verified strict-review failure, remediation `attemptCount=2`, а corrective decision
51
+ отсутствует, используйте только внешний runner `2.0.0-alpha.6.2`. Dependency проекта при этом
52
+ остаётся точно `2.0.0-alpha.6`.
53
+
54
+ Сначала выполните mutation-free `update corrective-rescue-preflight`. Он требует clean checkout
55
+ на exact HEAD `5c63798cc7b8fbb5e1c8b26ebf93876bc642295a`, неизменные Brief/Plan/Milestone bindings,
56
+ claimed C1 и ровно один token-bound lease. Stale lease допустим только при точном совпадении
57
+ claimant/token binding; plaintext token команда не возвращает.
58
+
59
+ При `eligible=true` команда `update corrective-rescue-apply` принимает исходный actor/token,
60
+ полный corrective Plan, independent `continue-fix` decision audit и отдельный independent Plan
61
+ audit. Она использует канонические переходы, heartbeat'ит существующий lease только после
62
+ проверки actor/token и не удаляет его. Нельзя вручную редактировать state, Brief, Step 2,
63
+ requirements/acceptance или Milestone scope.
64
+
25
65
  ## 1. Подготовьте отдельный чат обновления
26
66
 
27
67
  Не обновляйте пакет во время выполняющегося Worker Step. Дождитесь завершения текущего ответа
@@ -1,11 +1,15 @@
1
1
  # V2 Alpha Validation Report
2
2
 
3
- Release candidate `2.0.0-alpha.6` was validated through 2026-08-14 with Node.js 24.17.0.
3
+ Release candidate `2.0.0-alpha.6.2` was validated on 2026-08-14 with Node.js 20.12.2 as a
4
+ narrow backport from the `2.0.0-alpha.6.1` backport line, itself based on published
5
+ `2.0.0-alpha.6`.
4
6
 
5
7
  - `npm run typecheck`, `npm run build`, `npm test`, `npm run validate`, `npm run plugin:check`,
6
8
  `npm run smoke:downstream`, `npm run release:check`, and `npm run pack:check` passed in the
7
- task evidence recorded for TASK-002.
8
- - The final sequential full suite passed `81/81` on 2026-08-14.
9
+ sequential backport validation.
10
+ - The final sequential full suite passed `89/89` on 2026-08-14.
11
+ - The package test script runs test files sequentially; the unsupported
12
+ `--test-force-exit` flag was removed.
9
13
  - Plan Risk Audit coverage includes the combined `plan-set --risk-audit-file` path, atomic
10
14
  rejection before Task/Plan acceptance, distinct planner/auditor identities, exact current
11
15
  Step-set equality, concrete failure modes, executable evidence binding, coupled
@@ -14,9 +18,20 @@ Release candidate `2.0.0-alpha.6` was validated through 2026-08-14 with Node.js
14
18
  - Strict high-risk Step Review coverage includes workflow-owned completion commits,
15
19
  `task step-review` routing, commit-bound reviewer attestation, and fail-closed rejection of
16
20
  stale, malformed, unverified, and wrong-commit review evidence.
21
+ - Alpha.6.1 rescue coverage reproduces the production deadlock with an exact alpha.6
22
+ dependency, stale Knowledge binding, pending strict review, claimed C1 posture, and both
23
+ active and stale bound leases. The single rescue action preserves the original lease,
24
+ exposes no plaintext token, completes review with the exact claimant/token, and fails closed
25
+ for a wrong actor or token. Ordinary `task step-review` remains blocked by stale Knowledge.
17
26
  - Guarded remediation coverage includes the per-Step circuit breaker: two ordinary retries
18
- allowed, third gated by bounded `continue-fix`, a hard stop after a third failed corrective
19
- review, and stop/redirection handling for `split-required` and `stop-escalate`.
27
+ allowed, the third gated by a separate decision plus full independently audited corrective
28
+ Plan, an explicit corrective run envelope, a hard stop after a third failed corrective
29
+ review, and stop/redirection handling for `split-required` and `stop-escalate`. Knowledge
30
+ rebind and reauthorization preserve this breaker posture.
31
+ - Signal_v4 rescue coverage includes exact alpha.6 dependency/HEAD/Task/review-history
32
+ matching, mutation-free preflight, active and stale bound leases without token disclosure,
33
+ wrong actor/token ordering before heartbeat, scope-preserving decision plus full Plan apply,
34
+ dirty/advanced checkout rejection, malformed/missing review evidence, and unrelated leases.
20
35
  - Milestone coverage includes human-only scope-change prepare/apply, journaled recovery of
21
36
  `state.json`, `plan.json`, and `scope-change-events.jsonl`, plus membership-integrity
22
37
  blocking for stale or contradictory Milestone/Task state, including reverse detection of a
@@ -35,13 +50,16 @@ Release candidate `2.0.0-alpha.6` was validated through 2026-08-14 with Node.js
35
50
  `plan-risk-audit-sidecar-v1`, `step-strict-review-sidecar-v1`,
36
51
  `step-remediation-circuit-breaker-sidecar-v1`, `milestone-scope-change-sidecar-v1`,
37
52
  `milestone-membership-integrity-v1`, `task-c1-handoff-sidecar-v1`, and
38
- `alpha6-adoption-posture-v1`, plus strengthened contracts advertised as
53
+ `alpha6-adoption-posture-v1`, `alpha6-c1-strict-review-rescue-v1`, and
54
+ `alpha6-corrective-rescue-signal-v4`, plus strengthened contracts advertised as
39
55
  `semantic-plan-risk-audit-v2`, `guarded-remediation-hard-stop-v1`,
40
56
  `milestone-reverse-membership-integrity-v1`, and `task-c1-handoff-bundle-v2`.
41
- - npm dry-run packaging produced `codex-workflow-v2-2.0.0-alpha.6.tgz` with runtime, schemas,
57
+ - npm dry-run packaging produced `codex-workflow-v2-2.0.0-alpha.6.2.tgz` with runtime, schemas,
42
58
  references, docs, and plugin source. Downstream installation and the packaged CLI handshake
43
59
  passed, and the install created none of `.codex`, `.tasks`, `.increments`, or
44
60
  `.memory-bank` in the temporary project.
61
+ - Release checks require the dedicated `backport-alpha6` npm dist-tag, so publishing this
62
+ version cannot move the alpha.7-owned `next` tag.
45
63
 
46
64
  Not claimed here:
47
65
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codex-workflow-v2",
3
- "version": "2.0.0-alpha.6",
3
+ "version": "2.0.0-alpha.6.2",
4
4
  "description": "Requirements-first Codex development workflow with local state and explicit Git ownership.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -40,7 +40,7 @@
40
40
  "clean": "node --eval \"import('node:fs').then(({rmSync}) => { rmSync('dist', {recursive:true, force:true}); rmSync('.test-dist', {recursive:true, force:true}); })\"",
41
41
  "build": "npm run clean && tsc -p tsconfig.build.json && node scripts/mark-cli-executable.mjs",
42
42
  "typecheck": "tsc -p tsconfig.json --noEmit",
43
- "test": "npm run build && tsc -p tsconfig.test.json && node --test .test-dist/tests/*.test.js",
43
+ "test": "npm run build && tsc -p tsconfig.test.json && node --test --test-concurrency=1 .test-dist/tests/*.test.js",
44
44
  "validate": "npm run typecheck && npm test",
45
45
  "pack:check": "npm run build && npm pack --dry-run",
46
46
  "smoke:downstream": "npm run build && node scripts/downstream-smoke.mjs",
@@ -120,6 +120,11 @@ Task authorization evidence. Any semantic map change remains on the normal visib
120
120
 
121
121
  Before updating the installed package, run `update preflight`. Continue only for `safe=true`.
122
122
 
123
+ Alpha.6.1 adds one compatibility exception before package update: an exact alpha.6 claimed-C1
124
+ pending strict review with stale Knowledge may use external `update rescue-preflight` followed
125
+ by its single `update rescue-review` action. The action must preserve the original lease and
126
+ prove its bound actor/token; `locks repair` is forbidden before this review.
127
+
123
128
  ## C1 handoff
124
129
 
125
130
  `C1` coordination is machine-bound and local. Use:
@@ -110,6 +110,13 @@ replan, split, or stop decisions.
110
110
  Before an npm package update, run the project-local `update preflight` and stop unless it
111
111
  returns `safe=true` with a clean checkout, no running Step, and no active writer lease.
112
112
 
113
+ For a project still pinned exactly to `2.0.0-alpha.6` with one claimed-C1 pending strict review
114
+ blocked by stale Project Knowledge, do not update the dependency and do not repair the lease.
115
+ Resolve the exact external `2.0.0-alpha.6.1` runner, run its read-only `update rescue-preflight`,
116
+ and continue only for `eligible=true` with the single returned `update rescue-review` action.
117
+ Use the exact claimant and original bound writer token without printing the token. Stop on any
118
+ binding mismatch or additional blocker.
119
+
113
120
  ## Stop Conditions
114
121
 
115
122
  - Dependency version is missing, ranged, or differs from the installed package.
@@ -43,6 +43,16 @@
43
43
  "stepId": { "type": "string", "pattern": "^STEP-[0-9]{3}(?:-[A-Z0-9-]+)?$" },
44
44
  "expectedRevision": { "type": "integer", "minimum": 1 },
45
45
  "writerToken": { "type": ["string", "null"] },
46
+ "remediation": {
47
+ "type": "object",
48
+ "additionalProperties": false,
49
+ "required": ["attemptOrdinal", "mode", "correctiveDecisionEventId"],
50
+ "properties": {
51
+ "attemptOrdinal": { "type": "integer", "minimum": 1, "maximum": 3 },
52
+ "mode": { "enum": ["ordinary", "corrective"] },
53
+ "correctiveDecisionEventId": { "type": ["string", "null"] }
54
+ }
55
+ },
46
56
  "knowledgeMap": {
47
57
  "type": "object",
48
58
  "additionalProperties": false,
@@ -0,0 +1,47 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://codex-workflow.local/schemas/corrective-plan-audit-record.schema.json",
4
+ "title": "Codex Workflow V2 Alpha.6 Corrective Plan Audit Binding",
5
+ "type": "object",
6
+ "additionalProperties": false,
7
+ "required": [
8
+ "recordedAt",
9
+ "taskId",
10
+ "taskRevision",
11
+ "stepId",
12
+ "triggeringAttemptCount",
13
+ "decisionEventId",
14
+ "decisionPlanHash",
15
+ "previousPlanHash",
16
+ "correctivePlanHash",
17
+ "failedReviewAttempts",
18
+ "auditor",
19
+ "summary",
20
+ "decision",
21
+ "reviewedFindingIds"
22
+ ],
23
+ "properties": {
24
+ "recordedAt": { "type": "string", "format": "date-time" },
25
+ "taskId": { "type": "string", "pattern": "^TASK-[0-9A-HJKMNP-TV-Z]{26}$" },
26
+ "taskRevision": { "type": "integer", "minimum": 0 },
27
+ "stepId": { "type": "string", "pattern": "^STEP-[0-9]{3}(?:-[A-Z0-9-]+)?$" },
28
+ "triggeringAttemptCount": { "const": 3 },
29
+ "decisionEventId": { "type": "string", "minLength": 1 },
30
+ "decisionPlanHash": { "$ref": "#/$defs/hash64" },
31
+ "previousPlanHash": { "$ref": "#/$defs/hash64" },
32
+ "correctivePlanHash": { "$ref": "#/$defs/hash64" },
33
+ "failedReviewAttempts": { "const": 2 },
34
+ "auditor": { "type": "string", "minLength": 1 },
35
+ "summary": { "type": "string", "minLength": 1 },
36
+ "decision": { "const": "continue-fix" },
37
+ "reviewedFindingIds": {
38
+ "type": "array",
39
+ "minItems": 1,
40
+ "uniqueItems": true,
41
+ "items": { "type": "string", "minLength": 1 }
42
+ }
43
+ },
44
+ "$defs": {
45
+ "hash64": { "type": "string", "pattern": "^[a-f0-9]{64}$" }
46
+ }
47
+ }