worktree-controller 1.30.4__py3-none-any.whl
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.
- worktree_controller/__init__.py +3 -0
- worktree_controller/activation_layout.py +483 -0
- worktree_controller/branch_retirement.py +1865 -0
- worktree_controller/canonical_refresh.py +150 -0
- worktree_controller/canonical_transition.py +324 -0
- worktree_controller/cleanup_attempts.py +442 -0
- worktree_controller/cleanup_evidence.py +75 -0
- worktree_controller/cleanup_recovery.py +912 -0
- worktree_controller/cli.py +1907 -0
- worktree_controller/controller.py +1974 -0
- worktree_controller/convergence.py +893 -0
- worktree_controller/delivered_closeout.py +928 -0
- worktree_controller/disposable.py +677 -0
- worktree_controller/environment.py +1038 -0
- worktree_controller/frozen_recovery.py +291 -0
- worktree_controller/git_backend.py +682 -0
- worktree_controller/governance.py +365 -0
- worktree_controller/hardlinks.py +294 -0
- worktree_controller/integration_cleanup.py +92 -0
- worktree_controller/integration_conflict.py +117 -0
- worktree_controller/integration_retry.py +526 -0
- worktree_controller/keyed_document_scope.py +162 -0
- worktree_controller/lifecycle.py +8992 -0
- worktree_controller/lifecycle_history.py +358 -0
- worktree_controller/lifecycle_observation.py +234 -0
- worktree_controller/metadata_codec.py +1694 -0
- worktree_controller/metadata_relocation.py +131 -0
- worktree_controller/models.py +546 -0
- worktree_controller/mount_diagnostics.py +324 -0
- worktree_controller/multiple_cleanup_recovery.py +730 -0
- worktree_controller/namespace_migration.py +1412 -0
- worktree_controller/native_session_recovery.py +171 -0
- worktree_controller/owner_actions.py +34 -0
- worktree_controller/policy.py +333 -0
- worktree_controller/preservation.py +983 -0
- worktree_controller/preserved_cleanup.py +849 -0
- worktree_controller/publication_execution.py +361 -0
- worktree_controller/reconciler.py +430 -0
- worktree_controller/recovery_guidance.py +205 -0
- worktree_controller/registration_backfill.py +166 -0
- worktree_controller/registration_prune.py +391 -0
- worktree_controller/rendering.py +179 -0
- worktree_controller/resource_admission.py +1736 -0
- worktree_controller/retirement_adapters.py +130 -0
- worktree_controller/retirement_execution.py +234 -0
- worktree_controller/semantics.py +459 -0
- worktree_controller/session.py +505 -0
- worktree_controller/session_admission.py +265 -0
- worktree_controller/source_cleanup.py +515 -0
- worktree_controller/source_preservation.py +692 -0
- worktree_controller/source_recovery.py +592 -0
- worktree_controller/store.py +1228 -0
- worktree_controller/tool_cli_contract.json +1791 -0
- worktree_controller/transaction_scope.py +876 -0
- worktree_controller/writer_lease.py +662 -0
- worktree_controller/writer_session.py +887 -0
- worktree_controller-1.30.4.dist-info/METADATA +3149 -0
- worktree_controller-1.30.4.dist-info/RECORD +61 -0
- worktree_controller-1.30.4.dist-info/WHEEL +4 -0
- worktree_controller-1.30.4.dist-info/entry_points.txt +5 -0
- worktree_controller-1.30.4.dist-info/licenses/LICENSE +202 -0
|
@@ -0,0 +1,1791 @@
|
|
|
1
|
+
{
|
|
2
|
+
"commands": [
|
|
3
|
+
{
|
|
4
|
+
"name": "acquire",
|
|
5
|
+
"operation_class": "git_worktree_mutation",
|
|
6
|
+
"result_contract": "worktree-controller/v1"
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
"name": "acquire-across",
|
|
10
|
+
"operation_class": "git_worktree_mutation",
|
|
11
|
+
"result_contract": "worktree-controller/v1"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"name": "acquire-when-free",
|
|
15
|
+
"operation_class": "git_worktree_mutation",
|
|
16
|
+
"result_contract": "worktree-controller/v1"
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
"name": "admission-queue",
|
|
20
|
+
"operation_class": "metadata_mutation",
|
|
21
|
+
"result_contract": "worktree-controller/v1"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"name": "adopt",
|
|
25
|
+
"operation_class": "metadata_mutation",
|
|
26
|
+
"result_contract": "worktree-controller/v1"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"name": "adopt-delivered",
|
|
30
|
+
"operation_class": "metadata_mutation",
|
|
31
|
+
"result_contract": "worktree-controller/v1"
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
"name": "binding-add",
|
|
35
|
+
"operation_class": "metadata_mutation",
|
|
36
|
+
"result_contract": "worktree-controller/v1"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"name": "binding-remove",
|
|
40
|
+
"operation_class": "metadata_mutation",
|
|
41
|
+
"result_contract": "worktree-controller/v1"
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"name": "binding-transfer",
|
|
45
|
+
"operation_class": "metadata_mutation",
|
|
46
|
+
"result_contract": "worktree-controller/v1"
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
"name": "branch-retirement-authorize",
|
|
50
|
+
"operation_class": "metadata_mutation",
|
|
51
|
+
"result_contract": "branch-retirement/v5"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"name": "branch-retirement-complete",
|
|
55
|
+
"operation_class": "metadata_mutation",
|
|
56
|
+
"result_contract": "branch-retirement/v5"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"name": "branch-retirement-executions",
|
|
60
|
+
"operation_class": "metadata_mutation",
|
|
61
|
+
"result_contract": "branch-retirement/v5"
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
"name": "branch-retirement-plan",
|
|
65
|
+
"operation_class": "metadata_mutation",
|
|
66
|
+
"result_contract": "branch-retirement/v1"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"name": "branch-retirement-record",
|
|
70
|
+
"operation_class": "metadata_mutation",
|
|
71
|
+
"result_contract": "branch-retirement/v1"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"name": "branch-retirement-status",
|
|
75
|
+
"operation_class": "read_only",
|
|
76
|
+
"result_contract": "branch-retirement/v1"
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"name": "branch-retirement-verify",
|
|
80
|
+
"operation_class": "read_only",
|
|
81
|
+
"result_contract": "branch-retirement/v2"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"name": "capabilities",
|
|
85
|
+
"operation_class": "read_only",
|
|
86
|
+
"result_contract": "worktree-controller/v1"
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"name": "canonical-refresh",
|
|
90
|
+
"operation_class": "git_worktree_mutation",
|
|
91
|
+
"result_contract": "worktree-controller/v1"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"name": "canonical-transition",
|
|
95
|
+
"operation_class": "git_worktree_mutation",
|
|
96
|
+
"result_contract": "worktree-controller/v1"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"name": "archive-retained",
|
|
100
|
+
"operation_class": "metadata_mutation",
|
|
101
|
+
"result_contract": "worktree-controller/v1"
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
"name": "close-delivered",
|
|
105
|
+
"operation_class": "metadata_mutation",
|
|
106
|
+
"result_contract": "worktree-controller/v1"
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
"name": "close-preserved",
|
|
110
|
+
"operation_class": "metadata_mutation",
|
|
111
|
+
"result_contract": "worktree-controller/v1"
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
"name": "complete-no-change",
|
|
115
|
+
"operation_class": "metadata_mutation",
|
|
116
|
+
"result_contract": "worktree-controller/v1"
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
"name": "doctor",
|
|
120
|
+
"operation_class": "read_only",
|
|
121
|
+
"result_contract": "worktree-controller/v1"
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"name": "execution-admit",
|
|
125
|
+
"operation_class": "metadata_mutation",
|
|
126
|
+
"result_contract": "worktree-controller/v1"
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
"name": "execution-cancel",
|
|
130
|
+
"operation_class": "metadata_mutation",
|
|
131
|
+
"result_contract": "worktree-controller/v1"
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"name": "session-admit",
|
|
135
|
+
"operation_class": "git_worktree_mutation",
|
|
136
|
+
"result_contract": "worktree-controller/v1"
|
|
137
|
+
},
|
|
138
|
+
{
|
|
139
|
+
"name": "session-bind",
|
|
140
|
+
"operation_class": "metadata_mutation",
|
|
141
|
+
"result_contract": "worktree-controller/v1"
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
"name": "externalize",
|
|
145
|
+
"operation_class": "metadata_mutation",
|
|
146
|
+
"result_contract": "worktree-controller/v1"
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
"name": "gc-apply",
|
|
150
|
+
"operation_class": "git_worktree_mutation",
|
|
151
|
+
"result_contract": "worktree-governance/v1"
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"name": "gc-plan",
|
|
155
|
+
"operation_class": "read_only",
|
|
156
|
+
"result_contract": "worktree-governance/v2"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"name": "handoff",
|
|
160
|
+
"operation_class": "metadata_mutation",
|
|
161
|
+
"result_contract": "worktree-controller/v1"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"name": "host-execution",
|
|
165
|
+
"operation_class": "metadata_mutation",
|
|
166
|
+
"result_contract": "worktree-controller/v1"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
"name": "integration-abandon",
|
|
170
|
+
"operation_class": "metadata_mutation",
|
|
171
|
+
"result_contract": "worktree-controller/v1"
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"name": "integration-abort",
|
|
175
|
+
"operation_class": "metadata_mutation",
|
|
176
|
+
"result_contract": "worktree-controller/v1"
|
|
177
|
+
},
|
|
178
|
+
{
|
|
179
|
+
"name": "integration-retry",
|
|
180
|
+
"operation_class": "metadata_mutation",
|
|
181
|
+
"result_contract": "worktree-controller/v1"
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
"name": "integration-claim",
|
|
185
|
+
"operation_class": "git_worktree_mutation",
|
|
186
|
+
"result_contract": "worktree-controller/v1"
|
|
187
|
+
},
|
|
188
|
+
{
|
|
189
|
+
"name": "integration-enqueue",
|
|
190
|
+
"operation_class": "metadata_mutation",
|
|
191
|
+
"result_contract": "worktree-controller/v1"
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
"name": "integration-equivalent",
|
|
195
|
+
"operation_class": "metadata_mutation",
|
|
196
|
+
"result_contract": "worktree-controller/v1"
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
"name": "integration-queue",
|
|
200
|
+
"operation_class": "read_only",
|
|
201
|
+
"result_contract": "worktree-controller/v1"
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"name": "integration-recovery-matrix",
|
|
205
|
+
"operation_class": "read_only",
|
|
206
|
+
"result_contract": "worktree-controller/v1"
|
|
207
|
+
},
|
|
208
|
+
{
|
|
209
|
+
"name": "integration-resolve",
|
|
210
|
+
"operation_class": "metadata_mutation",
|
|
211
|
+
"result_contract": "worktree-controller/v1"
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"name": "integration-refresh",
|
|
215
|
+
"operation_class": "git_worktree_mutation",
|
|
216
|
+
"result_contract": "worktree-controller/v1"
|
|
217
|
+
},
|
|
218
|
+
{
|
|
219
|
+
"name": "integration-reopen",
|
|
220
|
+
"operation_class": "metadata_mutation",
|
|
221
|
+
"result_contract": "worktree-controller/v1"
|
|
222
|
+
},
|
|
223
|
+
{
|
|
224
|
+
"name": "integration-validate",
|
|
225
|
+
"operation_class": "metadata_mutation",
|
|
226
|
+
"result_contract": "worktree-controller/v1"
|
|
227
|
+
},
|
|
228
|
+
{
|
|
229
|
+
"name": "lease-abort",
|
|
230
|
+
"operation_class": "metadata_mutation",
|
|
231
|
+
"result_contract": "worktree-controller/v1"
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
"name": "lease-acquire",
|
|
235
|
+
"operation_class": "remote_tracking_mutation",
|
|
236
|
+
"result_contract": "worktree-controller/v1"
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
"name": "publication-execution-session",
|
|
240
|
+
"operation_class": "read_only",
|
|
241
|
+
"result_contract": "integration-publication-session/v1"
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
"name": "lease-complete",
|
|
245
|
+
"operation_class": "remote_tracking_mutation",
|
|
246
|
+
"result_contract": "worktree-controller/v1"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"name": "lifecycle-event-ack",
|
|
250
|
+
"operation_class": "metadata_mutation",
|
|
251
|
+
"result_contract": "worktree-controller/v1"
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"name": "lifecycle-events",
|
|
255
|
+
"operation_class": "read_only",
|
|
256
|
+
"result_contract": "worktree-controller/v1"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"name": "namespace-migrate",
|
|
260
|
+
"operation_class": "filesystem_mutation",
|
|
261
|
+
"result_contract": "namespace-migration/v1"
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
"name": "namespace-migration-plan",
|
|
265
|
+
"operation_class": "read_only",
|
|
266
|
+
"result_contract": "namespace-migration/v1"
|
|
267
|
+
},
|
|
268
|
+
{
|
|
269
|
+
"name": "namespace-migration-receipts",
|
|
270
|
+
"operation_class": "read_only",
|
|
271
|
+
"result_contract": "namespace-migration/v1"
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
"name": "namespace-migration-verify",
|
|
275
|
+
"operation_class": "read_only",
|
|
276
|
+
"result_contract": "namespace-migration/v1"
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
"name": "park",
|
|
280
|
+
"operation_class": "metadata_mutation",
|
|
281
|
+
"result_contract": "worktree-controller/v1"
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
"name": "plan",
|
|
285
|
+
"operation_class": "read_only",
|
|
286
|
+
"result_contract": "worktree-controller/v1"
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
"name": "quarantine",
|
|
290
|
+
"operation_class": "metadata_mutation",
|
|
291
|
+
"result_contract": "worktree-controller/v1"
|
|
292
|
+
},
|
|
293
|
+
{
|
|
294
|
+
"name": "reconcile",
|
|
295
|
+
"operation_class": "metadata_mutation",
|
|
296
|
+
"result_contract": "worktree-controller/v1"
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
"name": "reconcile-session",
|
|
300
|
+
"operation_class": "metadata_mutation",
|
|
301
|
+
"result_contract": "worktree-controller/v1"
|
|
302
|
+
},
|
|
303
|
+
{
|
|
304
|
+
"name": "reconcile-writers",
|
|
305
|
+
"operation_class": "metadata_mutation",
|
|
306
|
+
"result_contract": "worktree-controller/v1"
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
"name": "recovery-adopt",
|
|
310
|
+
"operation_class": "metadata_mutation",
|
|
311
|
+
"result_contract": "worktree-controller/v1"
|
|
312
|
+
},
|
|
313
|
+
{
|
|
314
|
+
"name": "release",
|
|
315
|
+
"operation_class": "git_worktree_mutation",
|
|
316
|
+
"result_contract": "worktree-controller/v1"
|
|
317
|
+
},
|
|
318
|
+
{
|
|
319
|
+
"name": "release-intent",
|
|
320
|
+
"operation_class": "metadata_mutation",
|
|
321
|
+
"result_contract": "worktree-controller/v1"
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
"name": "recover-handoff",
|
|
325
|
+
"operation_class": "metadata_mutation",
|
|
326
|
+
"result_contract": "worktree-controller/v1"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"name": "recover-published",
|
|
330
|
+
"operation_class": "git_worktree_mutation",
|
|
331
|
+
"result_contract": "worktree-controller/v1"
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
"name": "reopen",
|
|
335
|
+
"operation_class": "metadata_mutation",
|
|
336
|
+
"result_contract": "worktree-controller/v1"
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
"name": "resource-clean",
|
|
340
|
+
"operation_class": "resource_cleanup",
|
|
341
|
+
"result_contract": "worktree-controller/v1"
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
"name": "resource-recover",
|
|
345
|
+
"operation_class": "filesystem_mutation",
|
|
346
|
+
"result_contract": "re-preservation-recovery/v1"
|
|
347
|
+
},
|
|
348
|
+
{
|
|
349
|
+
"name": "resource-register",
|
|
350
|
+
"operation_class": "metadata_mutation",
|
|
351
|
+
"result_contract": "worktree-controller/v1"
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"name": "resume",
|
|
355
|
+
"operation_class": "metadata_mutation",
|
|
356
|
+
"result_contract": "worktree-controller/v1"
|
|
357
|
+
},
|
|
358
|
+
{
|
|
359
|
+
"name": "review",
|
|
360
|
+
"operation_class": "metadata_mutation",
|
|
361
|
+
"result_contract": "worktree-controller/v1"
|
|
362
|
+
},
|
|
363
|
+
{
|
|
364
|
+
"name": "status",
|
|
365
|
+
"operation_class": "read_only",
|
|
366
|
+
"result_contract": "worktree-controller/v1"
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
"name": "write-guard",
|
|
370
|
+
"operation_class": "read_only",
|
|
371
|
+
"result_contract": "worktree-controller/v1"
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
"name": "writer-lease-acquire",
|
|
375
|
+
"operation_class": "metadata_mutation",
|
|
376
|
+
"result_contract": "worktree-controller/v1"
|
|
377
|
+
},
|
|
378
|
+
{
|
|
379
|
+
"name": "writer-lease-release",
|
|
380
|
+
"operation_class": "metadata_mutation",
|
|
381
|
+
"result_contract": "worktree-controller/v1"
|
|
382
|
+
},
|
|
383
|
+
{
|
|
384
|
+
"name": "writer-session",
|
|
385
|
+
"operation_class": "metadata_mutation",
|
|
386
|
+
"result_contract": "writer-admission/v1"
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
"name": "lifecycle-history",
|
|
390
|
+
"operation_class": "read_only",
|
|
391
|
+
"result_contract": "closed-lifecycle/v1"
|
|
392
|
+
},
|
|
393
|
+
{
|
|
394
|
+
"name": "release-recovery-inspect",
|
|
395
|
+
"operation_class": "read_only",
|
|
396
|
+
"result_contract": "release-recovery-inspection/v1"
|
|
397
|
+
},
|
|
398
|
+
{
|
|
399
|
+
"name": "recovery-guide",
|
|
400
|
+
"operation_class": "read_only",
|
|
401
|
+
"result_contract": "worktree-controller/v1"
|
|
402
|
+
}
|
|
403
|
+
],
|
|
404
|
+
"branch_retirement_version": 1,
|
|
405
|
+
"branch_retirement_verify_version": 1,
|
|
406
|
+
"cleanup_hardlink_topology_version": 2,
|
|
407
|
+
"contract_version": 60,
|
|
408
|
+
"release_recovery_inspection_version": 1,
|
|
409
|
+
"release_recovery_inspection_contract": {
|
|
410
|
+
"contract": "release-recovery-inspection/v1",
|
|
411
|
+
"producer": "release-recovery-inspect --transaction-id <canonical-uuid> --json",
|
|
412
|
+
"request_fields": ["target_path", "expected_record_version", "owner_release", "publication_receipt_id", "release_intent_id"],
|
|
413
|
+
"identity": "exact original journal filename/UUID, supported release schema/phase, repository and ReleasePlan content hash, allocation, path, branch, HEAD and original CAS; referenced publication/intent identities must match",
|
|
414
|
+
"evidence": "raw SHA-256 and existing paths of the original journal and release plan, read under a shared repository lock",
|
|
415
|
+
"release_argv": "structured argument list for the existing guarded release, including original --publication-receipt-id and --intent-id when applicable; values are individual arguments, never a shell command",
|
|
416
|
+
"authority": "release_authorized=false and execution_guards_checked=false; no mutation, receipt creation, recovery execution, live guard preflight or activation exception; original owner/CAS come from the plan, never the released record; missing or inconsistent original evidence is refused"
|
|
417
|
+
},
|
|
418
|
+
"rollout_transaction_diagnostics_version": 1,
|
|
419
|
+
"rollout_transaction_diagnostics_contract": {
|
|
420
|
+
"contract": "rollout-transaction-diagnostics/v1",
|
|
421
|
+
"producer": "resource-recover --stage rollout-check --dry-run --json",
|
|
422
|
+
"field": "decision.transaction_diagnostics",
|
|
423
|
+
"fields": ["transaction_id", "command", "phase", "error", "recovery_entry"],
|
|
424
|
+
"error_fields": ["code", "message"],
|
|
425
|
+
"unavailable_identity": "command, phase and recovery_entry are null when not known; failed staged invocation diagnostics also have null transaction_id",
|
|
426
|
+
"consumer": "check-writer-rollout adds repository to each transaction_diagnostics row; controller-activate logs these rows before refusal",
|
|
427
|
+
"classification": "verified terminal evidence first; unfinished release requires the original release request, supported cleanup keeps its exact recovery checks, unknown commands or cleanup contracts remain refused",
|
|
428
|
+
"authority": "first refused transaction only; recovery_entry is a hint that still needs exact original identity and evidence; the check performs no metadata writes, automatic repair or new activation exception; release dry-run still refuses after checkout removal"
|
|
429
|
+
},
|
|
430
|
+
"canonical_transition_version": 1,
|
|
431
|
+
"canonical_refresh_version": 1,
|
|
432
|
+
"canonical_refresh_contract": {
|
|
433
|
+
"contract": "canonical-refresh/v1",
|
|
434
|
+
"producer": "canonical-refresh [--dry-run]",
|
|
435
|
+
"applies_to": "an ACTIVE canonical checkout on the policy publication branch that is clean, holds no writer lease, runtime binding or unfinished transaction, and is used by no live process other than the caller's own ancestry",
|
|
436
|
+
"action": "fetch the publication branch and fast-forward canonical only when its HEAD is an ancestor; the published policy must remain governable; Controller metadata is unchanged",
|
|
437
|
+
"results": ["CANONICAL_REFRESHED", "CANONICAL_CURRENT", "CANONICAL_REFRESH_READY"],
|
|
438
|
+
"refusals": ["CANONICAL_NOT_ACTIVE", "CANONICAL_BRANCH", "CANONICAL_DIRTY", "CANONICAL_IN_USE", "NON_FAST_FORWARD", "INTERRUPTED_TRANSACTION", "UNMANAGED_CANONICAL", "INVALID_POLICY"],
|
|
439
|
+
"frozen": "a HANDOFF_READY canonical keeps the exact canonical-transition flow",
|
|
440
|
+
"process_diagnostics": {
|
|
441
|
+
"location": "decision.process_diagnostics on live-process CANONICAL_IN_USE",
|
|
442
|
+
"fields": ["process_count", "processes", "processes_omitted", "recovery_steps", "retry_argv"],
|
|
443
|
+
"process_fields": ["pid", "name", "parent_pid", "metadata_status", "parent_name", "matched_paths", "paths_truncated"],
|
|
444
|
+
"limits": {"processes": 5, "paths_per_process": 3, "path_characters": 512, "name_characters": 64, "stat_characters": 4096},
|
|
445
|
+
"identity": "bounded current kernel stat metadata; missing, unreadable, malformed or oversized observations use unknown names/status and a null parent PID; parent metadata may independently be unknown",
|
|
446
|
+
"authority": "advisory only; original process-path evidence keeps the refusal, even if identity disappears; no command arguments, environments, native session mutation or automatic process termination",
|
|
447
|
+
"retry": "verify exact task/session ownership and other active shared-daemon work; normally close only the completed task-owned session; retry_argv requests guarded dry-run before refresh"
|
|
448
|
+
}
|
|
449
|
+
},
|
|
450
|
+
"canonical_transition_retirement_version": 1,
|
|
451
|
+
"canonical_transition_contract": {
|
|
452
|
+
"contract": "canonical-transition/v1",
|
|
453
|
+
"identity": "exact frozen record CAS, owner, branch, HEAD, old local main and expected remote main",
|
|
454
|
+
"mutation": "fast-forward local main, checkout with ignored-file overwrite disabled, then activate the canonical control-plane record",
|
|
455
|
+
"recovery": "retry exact pre-metadata ref or checkout progress; retain the frozen branch and its history evidence",
|
|
456
|
+
"guards": "clean attached canonical, complete handoff, no lease/binding/open intent, ancestral target, unoccupied main and valid target policy"
|
|
457
|
+
},
|
|
458
|
+
"canonical_main_refresh_version": 1,
|
|
459
|
+
"integration_lineage_admission_version": 1,
|
|
460
|
+
"integration_keyed_document_scope_version": 1,
|
|
461
|
+
"integration_keyed_document_scope_contract": {
|
|
462
|
+
"contract": "integration-keyed-document-scope/v1",
|
|
463
|
+
"entry_points": "normal enqueue, claim, reconcile and retry scope checks",
|
|
464
|
+
"identity": "original frozen source commits, scopes and queue sequence; no mutable checkout evidence",
|
|
465
|
+
"supported_document": "docs/handbook/business-progress.json, quant-platform schema 2, unchanged committed qp-handbook-progress merge profile",
|
|
466
|
+
"proof": "unique non-ancestor merge base for every frozen source pair; whole-record changed keys must be disjoint across tasks.authority_key and development_lines/modules/decisions.id",
|
|
467
|
+
"bounds": "at most 8 sources per intent, 2 MiB regular document blobs, 64 KiB attributes blobs",
|
|
468
|
+
"fail_closed": "shared record, metadata/schema/order changes, broad paths, code overlap, duplicate keys, invalid/missing/oversized Git evidence, ancestry dependency, explicit prerequisite or earlier publishing/recovery/attention state",
|
|
469
|
+
"authority": "preparation only; all ownership, resource admission, fresh candidate validation, main CAS and serialized publication gates remain"
|
|
470
|
+
},
|
|
471
|
+
"integration_lineage_admission_contract": {
|
|
472
|
+
"contract": "integration-lineage-admission/v1",
|
|
473
|
+
"entry_point": "integration-claim through the original frozen integration intent",
|
|
474
|
+
"identity": "unchanged intent, source allocation/handoff/branch/Finalizer/Snapshot, scope and queue sequence",
|
|
475
|
+
"admission": "a different integration task may share its allocated feature/audit/hotfix/emergency source authority only after the repository producer verifies that exact frozen lineage under its lock; request fingerprints and durable source rows stay unchanged",
|
|
476
|
+
"idempotency": "an exact repeated claim of an unchanged clean PREPARING_INTEGRATION candidate observes its existing identity without allocating, reserving, emitting events, validating or granting publication authority",
|
|
477
|
+
"guards": "same-task request drift and unrelated shared-authority requests remain refused; scope fences and resource budgets remain enforced; RESOURCE_WAIT never reports a candidate as claimed"
|
|
478
|
+
},
|
|
479
|
+
"canonical_main_refresh_contract": {
|
|
480
|
+
"contract": "canonical-main-refresh/v1",
|
|
481
|
+
"entry_point": "canonical-transition with expected branch equal to the policy publication branch (main or master)",
|
|
482
|
+
"identity": "exact frozen record CAS, owner and handoff HEAD, observed local main HEAD and expected remote main HEAD",
|
|
483
|
+
"mutation": "validate the immutable published policy, then fast-forward the checked-out main with ignored-file overwrite disabled; append CANONICAL_MAIN_REFRESHED and activate the control-plane record only after exact remote verification",
|
|
484
|
+
"recovery": "preserve advanced main and unchanged frozen metadata on interruption; retry with the observed local main HEAD, proving frozen HEAD -> observed main -> exact published target ancestry; never rewind main",
|
|
485
|
+
"retained_evidence": "the original handoff history and Finalizer identity; no extra baseline branch, release receipt or retirement proof",
|
|
486
|
+
"guards": "all canonical-transition guards remain; unpublished or divergent main, invalid published policy and ignored-file collisions fail closed"
|
|
487
|
+
},
|
|
488
|
+
"published_checkout_recovery_version": 1,
|
|
489
|
+
"capabilities_version": 1,
|
|
490
|
+
"storage_layout_version": 5,
|
|
491
|
+
"storage_layout": {
|
|
492
|
+
"version": 5,
|
|
493
|
+
"root": "<git-common-dir>/worktree-controller/v1",
|
|
494
|
+
"lock": {
|
|
495
|
+
"name": "repo.lock",
|
|
496
|
+
"authority": "regular readable-writable non-symlink file; every Controller mutation and the Git Finalizer retirement path serialize on it; missing or unusable locks fail closed"
|
|
497
|
+
},
|
|
498
|
+
"directories": {
|
|
499
|
+
"records": "one metadata record JSON per allocation id",
|
|
500
|
+
"bindings": "one worktree-key binding JSON per governed checkout",
|
|
501
|
+
"transactions": "nonterminal mutation journals; interrupted atomic temp siblings are never records",
|
|
502
|
+
"teardown-receipts": "reproducible environment teardown evidence",
|
|
503
|
+
"completion-receipts": "tracked source cleanup completion evidence",
|
|
504
|
+
"integration-intents": "durable integration queue intents",
|
|
505
|
+
"prepared-candidate-receipts": "immutable candidate preparation receipts",
|
|
506
|
+
"integration-reconciliation-receipts": "integration reconciliation receipts",
|
|
507
|
+
"lifecycle-events": "durable lifecycle event outbox",
|
|
508
|
+
"namespace-migrations": "write-once legacy namespace migration receipts, keyed by plan id",
|
|
509
|
+
"lifecycle-event-acks": "event acknowledgement receipts",
|
|
510
|
+
"release-intents": "durable release intents",
|
|
511
|
+
"release-plans": "unified release plans",
|
|
512
|
+
"publication-receipts": "publication completion receipts",
|
|
513
|
+
"release-receipts": "formal allocation release receipts",
|
|
514
|
+
"registration-prune-receipts": "write-once registration-prune/v1 audit receipts; authoritative terminal and recovery proof for registration pruning, not repository identity or lock authority; included byte-for-byte in namespace migration merged digest and move/convergence, but not in the prior GC plan digest or metadata-reference-relocation/v1 cleanup inventory",
|
|
515
|
+
"branch-retirement-plans": "versioned retirement plans consumed by the Git Finalizer retirement verifier",
|
|
516
|
+
"branch-retirement-receipts": "independent local/remote retirement results",
|
|
517
|
+
"reconciliation-receipts": "writer reconciliation receipts",
|
|
518
|
+
"writer-leases": "exact writer lease documents",
|
|
519
|
+
"writer-reconciliation-receipts": "writer-only historical budget settlement receipts",
|
|
520
|
+
"source-cleanup": "per-transaction tracked source evidence trees",
|
|
521
|
+
"branch-retirement-authorizations": "single-use retirement execution grants and their immutable abandonment evidence",
|
|
522
|
+
"cleanup-actions": "per-transaction typed and preserved cleanup action evidence; used by earlier v4 runtimes and declared in v5",
|
|
523
|
+
"cleanup-recoveries": "per-transaction cleanup recovery records and terminal completions; used by earlier v4 runtimes and declared in v5",
|
|
524
|
+
"native-session-recoveries": "immutable archived native-session binding recovery evidence, one document per allocation record version; used by earlier v4 runtimes and declared in v5",
|
|
525
|
+
"session-closeouts": "session-closeout/v1 observations keyed by exact holder identity; a document whose holder is provably gone is pruned when another observation is written; used by earlier v4 runtimes and declared in v5",
|
|
526
|
+
"binding-registrations": "worktree-registration/v1 identity of each linked binding written from v5: allocation, Git administrative directory and token; the same token is written to <git-common-dir>/<admin_dir>/worktree-controller-registration, and a live administrative directory without the matching marker withdraws the binding as BINDING_IDENTITY_DRIFT"
|
|
527
|
+
},
|
|
528
|
+
"single_file": {
|
|
529
|
+
"repo.json": "repository identity",
|
|
530
|
+
"publication-lease.json": "single publication lease",
|
|
531
|
+
"namespace-relocation.json": "fenced layout migration reference evidence"
|
|
532
|
+
},
|
|
533
|
+
"consumers": [
|
|
534
|
+
"worktree-controller itself (exclusive writers)",
|
|
535
|
+
"scripts/check-writer-rollout (frozen read-only activation gate)",
|
|
536
|
+
"Git Finalizer retirement verifier (reads branch-retirement-plans under repo.lock)"
|
|
537
|
+
],
|
|
538
|
+
"compatibility": "v5 declares four directories already used by earlier v4 runtimes (cleanup-actions, cleanup-recoveries, native-session-recoveries, session-closeouts) and adds exactly one directory (binding-registrations) plus the per-registration Git administrative marker worktree-controller-registration; no data moves and all v4 names, file identities and record and binding schemas remain unchanged; a binding without a registration document keeps its v4 meaning, v4 readers may ignore the added directory, and exact layout pins must recognize v5 before activation; v4 declares exactly one directory (registration-prune-receipts) already used by 1.9.2; no data moves and all v3 names, file identities and record schemas remain unchanged; v3 readers of existing paths may ignore the extra directory, while exact layout pins must recognize v4 before activation; v3 adds exactly one directory (namespace-migrations) and one documented previous-namespace entry (codex-worktree/v1, migrated only by the namespace-migrate verb); v2 adds exactly one directory (branch-retirement-authorizations); any further layout or schema change requires a new layout version plus that gate, and external consumers pin this section"
|
|
539
|
+
},
|
|
540
|
+
"branch_retirement_contract": {
|
|
541
|
+
"contract": "branch-retirement/v5",
|
|
542
|
+
"version": 5,
|
|
543
|
+
"authority": "Controller eligibility and immutable plan; Git Finalizer local/remote ref mutation",
|
|
544
|
+
"plan_schema_version": 1,
|
|
545
|
+
"consumer_contract": [
|
|
546
|
+
"the Controller owns eligibility, plan identity, state digest and blocker policy",
|
|
547
|
+
"a consumer obtains a verdict from branch-retirement-verify or a grant from branch-retirement-authorize",
|
|
548
|
+
"an authorized run settles through branch-retirement-complete, never through a self-reported summary",
|
|
549
|
+
"external tools must not copy the canonicalization, digest recipe or blocker list",
|
|
550
|
+
"the consumer performs the Git compare-and-delete itself; the Controller never writes a ref",
|
|
551
|
+
"consumer-specific argument and summary vocabulary lives only in the compatibility adapter",
|
|
552
|
+
"a grant is single-use: verify reports RETIREMENT_AUTHORIZATION_ACTIVE for the granted operation only"
|
|
553
|
+
],
|
|
554
|
+
"identity": {
|
|
555
|
+
"plan_id": "sha256 over the canonical JSON encoding of the identity fields",
|
|
556
|
+
"canonicalization": "JSON object with keys sorted, ensure_ascii=false, separators (\",\",\":\"), UTF-8",
|
|
557
|
+
"identity_fields": [
|
|
558
|
+
"schema_version",
|
|
559
|
+
"repository_id",
|
|
560
|
+
"allocation_id",
|
|
561
|
+
"release_receipt_id",
|
|
562
|
+
"branch",
|
|
563
|
+
"expected_oid",
|
|
564
|
+
"remote",
|
|
565
|
+
"remote_ref",
|
|
566
|
+
"remote_tracking_ref",
|
|
567
|
+
"integrated_into",
|
|
568
|
+
"integrated_ref",
|
|
569
|
+
"expected_integrated_oid",
|
|
570
|
+
"classification",
|
|
571
|
+
"registration",
|
|
572
|
+
"controller_state_digest"
|
|
573
|
+
],
|
|
574
|
+
"optional_identity_fields": ["canonical_transition_evidence"],
|
|
575
|
+
"optional_identity_semantics": "include an optional field only when present; release-backed plans retain their exact previous identity recipe",
|
|
576
|
+
"excluded_from_identity": "observed ref states, checkout paths, eligibility and blockers are live observations, not identity"
|
|
577
|
+
},
|
|
578
|
+
"state_digest": {
|
|
579
|
+
"recipe": "sha256 over, in this order: for each authority directory, each relevant *.json sorted by path, the update sequence is relative POSIX path, a NUL byte, the exact file bytes, a NUL byte; then each authority single file bound to the allocation with the same sequence prefixed by its file name; then the literal bytes policy, a NUL byte, and the exact bytes of .agents/worktree-policy.toml, or <default> when that file is absent",
|
|
580
|
+
"authority_directories": [
|
|
581
|
+
"records",
|
|
582
|
+
"bindings",
|
|
583
|
+
"integration-intents",
|
|
584
|
+
"release-intents",
|
|
585
|
+
"release-plans",
|
|
586
|
+
"release-receipts",
|
|
587
|
+
"publication-receipts",
|
|
588
|
+
"reconciliation-receipts",
|
|
589
|
+
"writer-leases",
|
|
590
|
+
"transactions"
|
|
591
|
+
],
|
|
592
|
+
"authority_files": [
|
|
593
|
+
"publication-lease.json"
|
|
594
|
+
],
|
|
595
|
+
"relevance": "a document participates only when it binds the plan allocation or branch: allocation_id match, integration-intent source_allocations or source_branches, release-intent integration_allocation_id, release-plan or release-receipt branch, publication-receipt source_results source_allocation_id, and authority_files by allocation_id",
|
|
596
|
+
"excluded": "branch-retirement-plans and branch-retirement-receipts never participate, so recording local completion does not invalidate the remote half of the same plan",
|
|
597
|
+
"policy_authority": "<canonical repository path>/.agents/worktree-policy.toml is the only policy source"
|
|
598
|
+
},
|
|
599
|
+
"verify": {
|
|
600
|
+
"command": "branch-retirement-verify --repo <path> --plan-id <sha256> --operation {local,remote}",
|
|
601
|
+
"lock": "shared repository lock held for the whole observation; no state is written, so callers run it before taking an exclusive retirement execution lock",
|
|
602
|
+
"plan_schema_binding": "plan.schema_version is the retirement authority pin; this contract surface is branch_retirement_contract.version",
|
|
603
|
+
"verdicts": {
|
|
604
|
+
"RETIREMENT_EXECUTABLE": "the plan's exact expected OID may be CAS-compared now",
|
|
605
|
+
"RETIREMENT_STALE": "authority or OID movement invalidated the plan; replan instead of mutating",
|
|
606
|
+
"RETIREMENT_BLOCKED": "occupancy, lease, intent, transaction, ancestry or unattested absence forbids mutation",
|
|
607
|
+
"RETIREMENT_OPERATION_COMPLETE": "an immutable receipt already records this operation for this plan"
|
|
608
|
+
},
|
|
609
|
+
"stale_blockers": [
|
|
610
|
+
"PLAN_STATE_DRIFT",
|
|
611
|
+
"LOCAL_OID_DRIFT",
|
|
612
|
+
"UPSTREAM_OID_DRIFT",
|
|
613
|
+
"CLASSIFICATION_*"
|
|
614
|
+
],
|
|
615
|
+
"absent_ref": "an unattested absent ref is RETIREMENT_BLOCKED with blocker ABSENT_UNATTESTED until a Finalizer summary proves the idempotent already-absent path and branch-retirement-record files the receipt",
|
|
616
|
+
"minimum_revalidation": [
|
|
617
|
+
"plan_id",
|
|
618
|
+
"operation",
|
|
619
|
+
"branch",
|
|
620
|
+
"expected_oid",
|
|
621
|
+
"expected_integrated_oid",
|
|
622
|
+
"integrated_ref",
|
|
623
|
+
"ref_state",
|
|
624
|
+
"controller_state_digest"
|
|
625
|
+
],
|
|
626
|
+
"remote_semantics": "remote ref_state observes the local remote-tracking ref; the Finalizer remains authoritative for the actual remote through its own fetch and expected-OID compare-and-delete"
|
|
627
|
+
},
|
|
628
|
+
"integration_modes": {
|
|
629
|
+
"automatic": [
|
|
630
|
+
"ANCESTRY"
|
|
631
|
+
],
|
|
632
|
+
"report_only": [
|
|
633
|
+
"CHERRY_EQUIVALENT",
|
|
634
|
+
"MERGE_ONLY",
|
|
635
|
+
"UNIQUE",
|
|
636
|
+
"MIXED",
|
|
637
|
+
"HISTORICAL_UNREGISTERED"
|
|
638
|
+
]
|
|
639
|
+
},
|
|
640
|
+
"eligible_allocations": {
|
|
641
|
+
"feature_audit": "released allocation with an immutable release receipt and direct ancestry",
|
|
642
|
+
"integration": "released allocation whose release plan links to the exact remote-verified publication receipt; repository, allocation, candidate, Finalizer and policy target identities must match",
|
|
643
|
+
"canonical_transition": "explicit branch selector with exactly one complete CANONICAL_TRANSITIONED event in the currently canonical-bound canonical/control-plane record; exact old HEAD and recorded main-before are ancestors of recorded main-after, itself contained in the current policy publication target on the recorded remote; registration CANONICAL_TRANSITION_BACKED and release_receipt_id null",
|
|
644
|
+
"integration_evidence_blocker": "INTEGRATION_PUBLICATION_NOT_VERIFIED"
|
|
645
|
+
},
|
|
646
|
+
"occupancy_gates": [
|
|
647
|
+
"no_checkout",
|
|
648
|
+
"released_allocation_or_active_frozen_canonical_transition_source",
|
|
649
|
+
"no_binding_or_writer_lease_except_exact_canonical_binding_for_transition_source",
|
|
650
|
+
"no_runtime_binding",
|
|
651
|
+
"no_unresolved_intent_or_transaction"
|
|
652
|
+
],
|
|
653
|
+
"completion": "independent idempotent local and remote receipts; never atomic",
|
|
654
|
+
"capability_binding": "branch_retirement_version stays pinned to plan.schema_version because the deployed Git Finalizer retirement verifier compares that capability against the plan schema; the verify surface is detected through branch_retirement_verify_version and contract_version",
|
|
655
|
+
"compatibility": [
|
|
656
|
+
"persisted plan schema stays 1 and v1 plans verify and authorize unchanged under this contract",
|
|
657
|
+
"transition-backed plans add canonical_transition_evidence to identity only when present; it binds the exact history event sha256, old HEAD, main before/after, remote, old owner and old Finalizer identity; canonical is never released and ordinary unregistered refs remain report-only",
|
|
658
|
+
"missing, invalid, ambiguous or drifted transition evidence fails closed; existing checkout, lease, runtime, recovery, intent, transaction and expected-OID gates remain mandatory",
|
|
659
|
+
"branch_retirement_version continues to mirror plan.schema_version for the deployed verifier",
|
|
660
|
+
"branch-retirement-verify keeps its four verdicts and its eight minimum_revalidation names",
|
|
661
|
+
"branch-retirement-plan, -status and -record keep their released payload keys",
|
|
662
|
+
"branch-retirement-record now refuses an operation holding a grant and a completion the Controller cannot observe; a fabricated result was never a valid retirement and no longer files a receipt",
|
|
663
|
+
"receipts gain provenance and result_contract; persisted receipts without them stay valid history",
|
|
664
|
+
"a further verdict, identity field, digest recipe or blocker change requires a new retirement contract version and a new contract_version"
|
|
665
|
+
],
|
|
666
|
+
"execution_authorization": {
|
|
667
|
+
"contract": "branch-retirement-execution/v1",
|
|
668
|
+
"capability": "branch_retirement_execution_version",
|
|
669
|
+
"verbs": [
|
|
670
|
+
"branch-retirement-authorize",
|
|
671
|
+
"branch-retirement-complete",
|
|
672
|
+
"branch-retirement-executions"
|
|
673
|
+
],
|
|
674
|
+
"authorization_identity_fields": [
|
|
675
|
+
"schema_version",
|
|
676
|
+
"contract",
|
|
677
|
+
"request_id",
|
|
678
|
+
"plan_id",
|
|
679
|
+
"operation",
|
|
680
|
+
"kind",
|
|
681
|
+
"repository_id",
|
|
682
|
+
"allocation_id",
|
|
683
|
+
"branch",
|
|
684
|
+
"ref",
|
|
685
|
+
"expected_oid",
|
|
686
|
+
"integrated_ref",
|
|
687
|
+
"expected_integrated_oid",
|
|
688
|
+
"tracking_ref",
|
|
689
|
+
"observed",
|
|
690
|
+
"controller_state_digest",
|
|
691
|
+
"holder_sha256",
|
|
692
|
+
"issued_at",
|
|
693
|
+
"expires_at"
|
|
694
|
+
],
|
|
695
|
+
"canonicalization": "JSON object with keys sorted, ensure_ascii=false, separators (\",\",\":\"), UTF-8",
|
|
696
|
+
"authorization_id": "sha256 over the canonical JSON encoding of the identity fields",
|
|
697
|
+
"token": {
|
|
698
|
+
"type": "string",
|
|
699
|
+
"sensitive": true,
|
|
700
|
+
"description": "a 256-bit Controller-generated capability returned only by authorize and compared constant-time at complete or abandon; it is excluded from the identity so it cannot change the authorization address"
|
|
701
|
+
},
|
|
702
|
+
"scope": "one plan, one operation, one use",
|
|
703
|
+
"binding": [
|
|
704
|
+
"controller_state_digest at issuance, using the frozen v1 recipe unchanged",
|
|
705
|
+
"an observation vector of the literal Git facts that recipe cannot see: watched ref to OID, checked-out paths, upstream ref and target, classification and blockers",
|
|
706
|
+
"the compare-and-delete tuple: ref, expected_oid, integrated_ref, expected_integrated_oid, tracking_ref"
|
|
707
|
+
],
|
|
708
|
+
"settlement": "complete takes the exclusive repository lock, re-observes the refs and re-derives the digest, and files a receipt only for exactly one authorized delta: the target ref moved from its expected OID to absent",
|
|
709
|
+
"abandonment": "the token holder, or a settled dead-holder observation, may close a grant; closing never files a receipt because absence alone does not prove who caused it, and writes immutable evidence instead",
|
|
710
|
+
"fence": "while a grant is outstanding: a second grant for the same plan and operation is refused, verify reports RETIREMENT_AUTHORIZATION_ACTIVE for the granted operation only, legacy branch-retirement-record refuses that operation, and MetadataStore.write_record refuses to create a new binding for the granted allocation with RETIREMENT_EXECUTION_ACTIVE",
|
|
711
|
+
"not_claimed": [
|
|
712
|
+
"a lock held by the caller: the Controller neither accepts nor verifies a caller lock assertion",
|
|
713
|
+
"prevention of an unauthorized plain-git mutation: it can be refused a receipt, not physically stopped",
|
|
714
|
+
"the remote operation's server-side fact: the Controller observes its own remote-tracking ref only"
|
|
715
|
+
],
|
|
716
|
+
"result_contract": "retirement-execution-result/v1",
|
|
717
|
+
"result_schema_version": 1,
|
|
718
|
+
"result_fields": [
|
|
719
|
+
"contract",
|
|
720
|
+
"executor",
|
|
721
|
+
"expected_integrated_oid",
|
|
722
|
+
"expected_oid",
|
|
723
|
+
"kind",
|
|
724
|
+
"operation",
|
|
725
|
+
"outcome",
|
|
726
|
+
"plan_id",
|
|
727
|
+
"ref",
|
|
728
|
+
"schema_version"
|
|
729
|
+
],
|
|
730
|
+
"result_optional_fields": [
|
|
731
|
+
"evidence",
|
|
732
|
+
"integrated_ref",
|
|
733
|
+
"performed_at"
|
|
734
|
+
],
|
|
735
|
+
"outcomes": [
|
|
736
|
+
"EXECUTION_FAILED",
|
|
737
|
+
"REF_ALREADY_ABSENT",
|
|
738
|
+
"REF_REMOVED_AT_EXPECTED_OID",
|
|
739
|
+
"REF_STILL_PRESENT"
|
|
740
|
+
],
|
|
741
|
+
"execution_kinds": [
|
|
742
|
+
"ATTEST_ABSENT",
|
|
743
|
+
"CAS_DELETE"
|
|
744
|
+
],
|
|
745
|
+
"grantable_kinds": [
|
|
746
|
+
"CAS_DELETE"
|
|
747
|
+
],
|
|
748
|
+
"reported_only_kinds": [
|
|
749
|
+
"ATTEST_ABSENT (a translated legacy consumer claim; never a grant, and refused by a grant settle)"
|
|
750
|
+
],
|
|
751
|
+
"holder": "self, or ancestor:<program> resolved from the caller's own process tree; a detached pid is refused with INVALID_HOLDER because naming somebody else's process proves nothing",
|
|
752
|
+
"provenance": {
|
|
753
|
+
"AUTHORIZED_EXECUTION": "settled through a grant and the Controller's own re-observation",
|
|
754
|
+
"CONTROLLER_OBSERVED": "legacy record where the Controller observed the ref gone and authority intact",
|
|
755
|
+
"CONSUMER_CLAIM": "receipts filed before this contract; persisted history, never re-creatable"
|
|
756
|
+
},
|
|
757
|
+
"authority_recheck": "record re-runs the full governance evaluation and refuses with EXECUTION_GOVERNANCE_MOVED when any authority_blockers entry appeared after the plan; ref-derived codes are expected from a deletion and are not refused",
|
|
758
|
+
"ref_derived_blockers": [
|
|
759
|
+
"EXPECTED_OID_MISSING",
|
|
760
|
+
"INTEGRATION_REF_MISSING",
|
|
761
|
+
"UPSTREAM_OID_DRIFT",
|
|
762
|
+
"UPSTREAM_TARGET_MISMATCH"
|
|
763
|
+
],
|
|
764
|
+
"directory": "branch-retirement-authorizations",
|
|
765
|
+
"grant_document_layout": "<git-common-dir>/worktree-controller/v1/branch-retirement-authorizations/<authorization_id>.json, with immutable <authorization_id>-abandoned.json evidence written beside it; the directory is not in the state digest, so a grant cannot invalidate the plan it authorizes",
|
|
766
|
+
"fault_points": [
|
|
767
|
+
"retirement_authorization_issued",
|
|
768
|
+
"retirement_receipt_written",
|
|
769
|
+
"retirement_abandon_started",
|
|
770
|
+
"retirement_abandon_evidence_written"
|
|
771
|
+
],
|
|
772
|
+
"abandonment_authority": "the execution token only; holder liveness is reported by inspect as information because flock dies with the process while the mutation may never have run",
|
|
773
|
+
"authority_blockers": [
|
|
774
|
+
"ALLOCATION_BOUND",
|
|
775
|
+
"ALLOCATION_NOT_RELEASED",
|
|
776
|
+
"ALLOCATION_RECORD_MISSING",
|
|
777
|
+
"BRANCH_CHECKED_OUT",
|
|
778
|
+
"CANONICAL_TRANSITION_ALLOCATION_INVALID",
|
|
779
|
+
"CANONICAL_TRANSITION_EVIDENCE_AMBIGUOUS",
|
|
780
|
+
"CANONICAL_TRANSITION_EVIDENCE_INVALID",
|
|
781
|
+
"CANONICAL_TRANSITION_PUBLICATION_MISMATCH",
|
|
782
|
+
"CANONICAL_TRANSITION_TARGET_MISMATCH",
|
|
783
|
+
"INTEGRATION_INTENT_UNRESOLVED",
|
|
784
|
+
"INTEGRATION_PUBLICATION_NOT_VERIFIED",
|
|
785
|
+
"PLAN_STATE_DRIFT",
|
|
786
|
+
"PROTECTED_BRANCH",
|
|
787
|
+
"PUBLICATION_LEASE_ACTIVE",
|
|
788
|
+
"RECOVERY_STATE_EXCLUDED",
|
|
789
|
+
"RELEASE_INTENT_UNRESOLVED",
|
|
790
|
+
"RUNTIME_BINDING_ACTIVE",
|
|
791
|
+
"SPECIAL_LIFECYCLE_REF",
|
|
792
|
+
"TRANSACTION_ACTIVE",
|
|
793
|
+
"UNSUPPORTED_ALLOCATION_ROLE",
|
|
794
|
+
"WRITER_LEASE_ACTIVE"
|
|
795
|
+
],
|
|
796
|
+
"fence_scope": "the allocation half of the fence is enforced at the single binding chokepoint; the branch half is prevented by acquire's existing BRANCH_EXISTS rule and detected at settlement by the observation vector, because a metadata record carries no branch name",
|
|
797
|
+
"verb_layer_blockers": [
|
|
798
|
+
"RETIREMENT_AUTHORIZATION_ACTIVE"
|
|
799
|
+
],
|
|
800
|
+
"compatibility_error_codes": [
|
|
801
|
+
"AUTHORIZATION_TOKEN_MISMATCH",
|
|
802
|
+
"AUTHORIZATION_TOKEN_REQUIRED",
|
|
803
|
+
"EXECUTION_GOVERNANCE_MOVED",
|
|
804
|
+
"EXECUTION_OBSERVATION_MISMATCH",
|
|
805
|
+
"EXECUTION_RESULT_MISMATCH",
|
|
806
|
+
"FINALIZER_RESULT_MISMATCH",
|
|
807
|
+
"INVALID_AUTHORIZATION_ID",
|
|
808
|
+
"INVALID_AUTHORIZATION_TTL",
|
|
809
|
+
"INVALID_EXECUTION_KIND",
|
|
810
|
+
"INVALID_EXECUTION_RESULT",
|
|
811
|
+
"INVALID_FINALIZER_SUMMARY",
|
|
812
|
+
"INVALID_HOLDER",
|
|
813
|
+
"INVALID_REQUEST_ID",
|
|
814
|
+
"RETIREMENT_EXECUTION_ACTIVE",
|
|
815
|
+
"UNKNOWN_RETIREMENT_AUTHORIZATION"
|
|
816
|
+
],
|
|
817
|
+
"expiry": "expiry means the claim needs verification, never that the work is done: an expired grant still fences occupancy, still requires settle or abandon with the token, and a settlement after expiry is recorded as grant_expired_at_settle rather than refused",
|
|
818
|
+
"plan_recipe": {
|
|
819
|
+
"contract": "retirement-execution-recipe/v1",
|
|
820
|
+
"schema_version": 1,
|
|
821
|
+
"fields": [
|
|
822
|
+
"contract",
|
|
823
|
+
"grant",
|
|
824
|
+
"operations",
|
|
825
|
+
"result_contract",
|
|
826
|
+
"schema_version",
|
|
827
|
+
"settle"
|
|
828
|
+
],
|
|
829
|
+
"operation_fields": [
|
|
830
|
+
"expected_integrated_oid",
|
|
831
|
+
"expected_oid",
|
|
832
|
+
"integrated_ref",
|
|
833
|
+
"kind",
|
|
834
|
+
"mutation",
|
|
835
|
+
"ref",
|
|
836
|
+
"tracking_ref"
|
|
837
|
+
],
|
|
838
|
+
"promise": "the recipe is what a grant later binds, so a consumer can prepare from the plan alone; it names no consumer product and carries no digest recipe"
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
},
|
|
842
|
+
"activation_layout_migration": {
|
|
843
|
+
"entrypoint": "scripts/controller-activate",
|
|
844
|
+
"previous_layout": "explicit namespace, policy path and installed entrypoint SHA256 bindings",
|
|
845
|
+
"writer_transition": "schema 1 holder.provider to schema 2 holder.client_id; identity and authority preserved",
|
|
846
|
+
"blockers": [
|
|
847
|
+
"unsupported or unverified unfinished transactions",
|
|
848
|
+
"publication leases",
|
|
849
|
+
"live evidence bound to previous paths",
|
|
850
|
+
"layout or entrypoint drift"
|
|
851
|
+
],
|
|
852
|
+
"rollback": "exact receipt and digest; inverse layout and lease conversion without replay",
|
|
853
|
+
"retirement": "explicit finish-layout after real client acceptance"
|
|
854
|
+
},
|
|
855
|
+
"entrypoint": "worktree-controller",
|
|
856
|
+
"holder_resolver_version": 1,
|
|
857
|
+
"host_managed_writer_session": {
|
|
858
|
+
"command": "writer-session host-check <actual-caller-path>",
|
|
859
|
+
"access_option": "--access read|exec|write; write requires --target <absolute-path>; writer-session check accepts the same options",
|
|
860
|
+
"context_environment": "CONTROLLER_WRITER_CONTEXT",
|
|
861
|
+
"mode": "host-managed-v2",
|
|
862
|
+
"operation_class": "read_only",
|
|
863
|
+
"required_context_fields": [
|
|
864
|
+
"holder",
|
|
865
|
+
"client_id",
|
|
866
|
+
"session_id",
|
|
867
|
+
"run_id",
|
|
868
|
+
"repository_path",
|
|
869
|
+
"worktree_path",
|
|
870
|
+
"allocation_id",
|
|
871
|
+
"lease_id"
|
|
872
|
+
],
|
|
873
|
+
"required_holder_fields": [
|
|
874
|
+
"pid",
|
|
875
|
+
"boot_id",
|
|
876
|
+
"start_ticks"
|
|
877
|
+
],
|
|
878
|
+
"success_code": "WRITE_ALLOWED"
|
|
879
|
+
},
|
|
880
|
+
"host_managed_writer_session_version": 2,
|
|
881
|
+
"host_handoff_continuation_version": 2,
|
|
882
|
+
"host_handoff_continuation_contract": {
|
|
883
|
+
"contract": "host-handoff-continuation/v2",
|
|
884
|
+
"producer": "writer-session host-check <actual-caller-path> | writer-session check <client> <path> <holder> --session-id <id>, each with --access read|exec|write [--target <absolute-path>]",
|
|
885
|
+
"admission": "CONTINUATION_GRANTED with code HOST_HANDOFF_CONTINUATION; exit 0 only for GRANTED or CONTINUATION_GRANTED",
|
|
886
|
+
"applies_to": "the exact live holder of the current lease on its own HANDOFF_READY or PRESERVED feature allocation, with no foreign runtime binding and no frozen HEAD drift",
|
|
887
|
+
"access_classes": ["read", "exec", "write"],
|
|
888
|
+
"write_targets": "outside Controller governance; another checkout whose writer lease this same live process (PID, boot ID, start ticks) holds and whose feature-write guard allows it; or an ACTIVE integration candidate whose source_allocations include the frozen allocation and whose integration-write guard allows it",
|
|
889
|
+
"performance": "entitlement checks evaluate the write guard without the full status scan and decode repository metadata once",
|
|
890
|
+
"handoff_scope": "handoff --scope-changed records the exact paths changed since the publication base for an unscoped feature task; an integration-ready handoff of unscoped changed work succeeds with warning MISSING_HANDOFF_SCOPE because integration-enqueue requires a scope",
|
|
891
|
+
"rollout_requirements": "a consumer may report required_controller_capabilities {name: minimum}; activation and rollback refuse a target runtime that does not advertise each minimum",
|
|
892
|
+
"fence": "the frozen checkout, other governed checkouts, other repositories and checks without --access keep the original refusal; leases, bindings and lifecycle are never mutated",
|
|
893
|
+
"consumer": "a host maps each tool call to one access class and target; authority remains this Controller decision"
|
|
894
|
+
},
|
|
895
|
+
"json_envelope": [
|
|
896
|
+
"tool_version",
|
|
897
|
+
"schema_version",
|
|
898
|
+
"command",
|
|
899
|
+
"repository",
|
|
900
|
+
"decision",
|
|
901
|
+
"worktrees",
|
|
902
|
+
"warnings",
|
|
903
|
+
"errors"
|
|
904
|
+
],
|
|
905
|
+
"metadata_schema_version": 4,
|
|
906
|
+
"operation_classes": [
|
|
907
|
+
"read_only",
|
|
908
|
+
"metadata_mutation",
|
|
909
|
+
"git_worktree_mutation",
|
|
910
|
+
"filesystem_mutation",
|
|
911
|
+
"resource_cleanup",
|
|
912
|
+
"remote_tracking_mutation"
|
|
913
|
+
],
|
|
914
|
+
"protected_operations": [
|
|
915
|
+
"automatic_owner_expiry",
|
|
916
|
+
"automatic_writer_reconciliation",
|
|
917
|
+
"branch_or_tag_deletion",
|
|
918
|
+
"canonical_release",
|
|
919
|
+
"fetch_outside_publication_lease",
|
|
920
|
+
"force_worktree_removal",
|
|
921
|
+
"multiple_main_publication_writers",
|
|
922
|
+
"unclassified_disposable_cleanup"
|
|
923
|
+
],
|
|
924
|
+
"release_options": [
|
|
925
|
+
"--intent-id",
|
|
926
|
+
"--publication-receipt-id",
|
|
927
|
+
"--teardown-reproducible-venv",
|
|
928
|
+
"--dry-run"
|
|
929
|
+
],
|
|
930
|
+
"typed_disposable_resource_contract": {
|
|
931
|
+
"version": 1,
|
|
932
|
+
"command": "resource-clean",
|
|
933
|
+
"options": [
|
|
934
|
+
"--typed",
|
|
935
|
+
"--dry-run",
|
|
936
|
+
"--expected-plan-id"
|
|
937
|
+
],
|
|
938
|
+
"paths": {
|
|
939
|
+
"backend/.venv": "python-venv",
|
|
940
|
+
"frontend/node_modules": "node-modules",
|
|
941
|
+
"frontend/dist": "frontend-build-output"
|
|
942
|
+
},
|
|
943
|
+
"dry_run_fields": [
|
|
944
|
+
"resource_type",
|
|
945
|
+
"path",
|
|
946
|
+
"classification",
|
|
947
|
+
"cleanup_action",
|
|
948
|
+
"blocker"
|
|
949
|
+
],
|
|
950
|
+
"runtime_authority_contract": "allocation-runtime-authority/v1",
|
|
951
|
+
"runtime_classifications": [
|
|
952
|
+
"MANAGED_REFERENCE",
|
|
953
|
+
"OBSERVED_REFERENCE",
|
|
954
|
+
"MANAGED_VISIBILITY_UNCERTAIN",
|
|
955
|
+
"HOST_VISIBILITY_GAP"
|
|
956
|
+
],
|
|
957
|
+
"host_visibility_gap": "warning-only-for-authenticated-typed-resources",
|
|
958
|
+
"ready_with_host_gap": "CLEANUP_READY_WITH_HOST_VISIBILITY_GAP",
|
|
959
|
+
"plan_evidence_fields": [
|
|
960
|
+
"runtime_evidence",
|
|
961
|
+
"warnings",
|
|
962
|
+
"hardlink_topology"
|
|
963
|
+
],
|
|
964
|
+
"receipt_evidence_fields": [
|
|
965
|
+
"plan",
|
|
966
|
+
"runtime_checks",
|
|
967
|
+
"post_scan",
|
|
968
|
+
"action_evidence"
|
|
969
|
+
],
|
|
970
|
+
"allocation_release": "separate-guarded-command"
|
|
971
|
+
},
|
|
972
|
+
"legacy_preserved_state_cleanup_contract": {
|
|
973
|
+
"contract": "legacy-preserved-state-cleanup/v1",
|
|
974
|
+
"preservation_contract": "legacy-preserved-state/v1",
|
|
975
|
+
"entrypoint": "python -m worktree_controller.preservation",
|
|
976
|
+
"commands": [
|
|
977
|
+
"plan",
|
|
978
|
+
"copy",
|
|
979
|
+
"verify"
|
|
980
|
+
],
|
|
981
|
+
"command": "resource-clean --typed",
|
|
982
|
+
"options": [
|
|
983
|
+
"--preservation-receipt",
|
|
984
|
+
"--preservation-receipt-sha256"
|
|
985
|
+
],
|
|
986
|
+
"source_path": ".venv",
|
|
987
|
+
"classification": "exact-preserved",
|
|
988
|
+
"cleanup_action": "remove-preserved-tree",
|
|
989
|
+
"ready_code": "CLEANUP_READY_WITH_PRESERVATION",
|
|
990
|
+
"runtime_authority_contract": "allocation-runtime-authority/v1",
|
|
991
|
+
"host_visibility_gap": "warning-and-immutable-evidence-without-host-wide-absence-claim",
|
|
992
|
+
"cleanup_order": [
|
|
993
|
+
"typed-disposable",
|
|
994
|
+
"exact-preserved"
|
|
995
|
+
],
|
|
996
|
+
"receipt_evidence_fields": [
|
|
997
|
+
"plan",
|
|
998
|
+
"actions",
|
|
999
|
+
"runtime_checks",
|
|
1000
|
+
"post_scan",
|
|
1001
|
+
"action_evidence"
|
|
1002
|
+
],
|
|
1003
|
+
"partial_failure": "immutable-receipt-and-retained-transaction-block-release",
|
|
1004
|
+
"allocation_release": "separate-guarded-command-with-destination-reverification"
|
|
1005
|
+
},
|
|
1006
|
+
"tracked_source_preservation_contract": {
|
|
1007
|
+
"contract": "tracked-source-preservation/v1",
|
|
1008
|
+
"entrypoint": "python -m worktree_controller.source_preservation",
|
|
1009
|
+
"commands": [
|
|
1010
|
+
"plan",
|
|
1011
|
+
"copy",
|
|
1012
|
+
"verify"
|
|
1013
|
+
],
|
|
1014
|
+
"scope": "unstaged modified tracked regular files only",
|
|
1015
|
+
"reconstruction": "base HEAD tree plus exact raw file overlay",
|
|
1016
|
+
"index_action": "none",
|
|
1017
|
+
"cleanup_authorized": false
|
|
1018
|
+
},
|
|
1019
|
+
"tracked_source_cleanup_contract": {
|
|
1020
|
+
"contract": "tracked-source-cleanup/v1",
|
|
1021
|
+
"entrypoint": "python -m worktree_controller.source_cleanup",
|
|
1022
|
+
"commands": [
|
|
1023
|
+
"plan",
|
|
1024
|
+
"execute"
|
|
1025
|
+
],
|
|
1026
|
+
"scope": "exact receipt-covered modified tracked files to bound HEAD",
|
|
1027
|
+
"execution_precondition": "current preservation receipt, generation, HEAD, index, file and parent identities match",
|
|
1028
|
+
"write_primitive": "verified single-link regular FD only",
|
|
1029
|
+
"partial_failure": "retain immutable evidence and transaction; no replay or release",
|
|
1030
|
+
"no_commit_completion": "current completion references archival evidence; no historical handoff assertion",
|
|
1031
|
+
"index_action": "none",
|
|
1032
|
+
"allocation_release": "separate existing lifecycle with source and generation reverification"
|
|
1033
|
+
},
|
|
1034
|
+
"transaction_conflict_contract": {
|
|
1035
|
+
"contract": "controller-transaction-conflict/v1",
|
|
1036
|
+
"conflict_scope": "nonterminal same-allocation or overlapping resource scopes under the repository mutation lock",
|
|
1037
|
+
"identity": [
|
|
1038
|
+
"repository_id",
|
|
1039
|
+
"allocation_id",
|
|
1040
|
+
"transaction_id",
|
|
1041
|
+
"target_path",
|
|
1042
|
+
"command",
|
|
1043
|
+
"cleanup_plan.contract",
|
|
1044
|
+
"phase"
|
|
1045
|
+
],
|
|
1046
|
+
"historical_terminal": "exact supported immutable terminal evidence; retained journals may coexist",
|
|
1047
|
+
"unknown_identity_or_lifecycle": "BLOCK"
|
|
1048
|
+
},
|
|
1049
|
+
"tracked_source_no_action_recovery_contract": {
|
|
1050
|
+
"contract": "tracked-source-no-action-recovery/v1",
|
|
1051
|
+
"entrypoint": "python -m worktree_controller.source_recovery",
|
|
1052
|
+
"commands": [
|
|
1053
|
+
"plan",
|
|
1054
|
+
"reconcile"
|
|
1055
|
+
],
|
|
1056
|
+
"scope": "transaction-scope refusal before tracked source action",
|
|
1057
|
+
"precondition": "empty actions and checks, no action evidence, exact source/index/HEAD/parents/preservation, runtime authority PASS",
|
|
1058
|
+
"state": "STARTED_NO_ACTION_RECOVERABLE",
|
|
1059
|
+
"terminal_attempt_state": "SOURCE_ATTEMPT_SUPERSEDED",
|
|
1060
|
+
"successor": "new single-use attempt identity bound by immutable reconciliation",
|
|
1061
|
+
"old_evidence": "retained byte-identical",
|
|
1062
|
+
"partial_action": "BLOCK"
|
|
1063
|
+
},
|
|
1064
|
+
"schema_version": 1,
|
|
1065
|
+
"session_launcher_entrypoint": "worktree-session",
|
|
1066
|
+
"session_entrypoint": "worktree-session-end",
|
|
1067
|
+
"tool_name": "worktree-controller",
|
|
1068
|
+
"tool_version": "1.30.4",
|
|
1069
|
+
"delivered_closeout_version": 1,
|
|
1070
|
+
"retained_archive_version": 1,
|
|
1071
|
+
"retention_convergence_version": 2,
|
|
1072
|
+
"session_end_selector_version": 1,
|
|
1073
|
+
"session_end_selector_contract": {
|
|
1074
|
+
"entrypoint": "worktree-session-end --path <inside-repository> --client-id <client> --session-id <session> --holder ancestor:<program>|<pid> [--run-id <recorded-run>]",
|
|
1075
|
+
"selection": "writer leases in that repository whose recorded holder equals the resolved live holder exactly, including client and session identity",
|
|
1076
|
+
"action": "release each exact lease, then the unchanged reconcile-session route: ACTIVE feature/audit is retained, HANDOFF_READY gets its release intent",
|
|
1077
|
+
"never": ["other sessions' leases", "hosted children (CONTROLLER_WRITER_MODE/CONTROLLER_WRITER_CONTEXT)", "--owner", "task completion claims"],
|
|
1078
|
+
"exit": "default always 0; use session-closeout/v1 per-allocation outcomes and summary, or --require-complete"
|
|
1079
|
+
},
|
|
1080
|
+
"gc_apply_replay_version": 1,
|
|
1081
|
+
"retention_convergence_contract": {
|
|
1082
|
+
"contract": "retention-convergence/v2",
|
|
1083
|
+
"entrypoint": "reconcile retention",
|
|
1084
|
+
"authority": "repository policy [convergence] delegated to the [reconciler] actor; apply refuses any other actor",
|
|
1085
|
+
"triggers": [
|
|
1086
|
+
"manual",
|
|
1087
|
+
"admission",
|
|
1088
|
+
"background"
|
|
1089
|
+
],
|
|
1090
|
+
"plan": "default is a read-only report; --apply acts",
|
|
1091
|
+
"candidates": "clean attached feature/audit checkouts in ACTIVE (dormant only), RETAINED, HANDOFF_READY, RELEASE_READY, ARCHIVED or NO_CHANGE_COMPLETED, plus hotfix HANDOFF_READY, without writer lease, live process, binding, publication lease or active integration lineage",
|
|
1092
|
+
"routes": {
|
|
1093
|
+
"close-delivered": "HEAD, base and task commit contained in the publication branch; waits grace_minutes",
|
|
1094
|
+
"complete-no-change": "HEAD equals base; waits grace_minutes",
|
|
1095
|
+
"release-published-handoff": "feature/audit/hotfix frozen handoff equals HEAD and is published; waits grace_minutes; a hotfix with an unregistered .venv waits for its owner attestation",
|
|
1096
|
+
"release-retained-handoff": "policy release_unintegrated_handoffs only: unpublished integration-ready feature/audit/hotfix handoff whose task, handoff and Finalizer identities, local branch and remote-tracking branch all equal HEAD and that no open integration intent references; waits the dynamic idle threshold; integration-enqueue later resolves the source branch from its release receipt while that branch still equals the handoff",
|
|
1097
|
+
"archive-retained": "unfinished commits stay on the retained branch; waits the dynamic idle threshold",
|
|
1098
|
+
"release": "already closed checkout; waits grace_minutes",
|
|
1099
|
+
"park": "dormant ACTIVE feature/audit allocation without lease, process, binding or publication lease; waits idle_hours_max (never shortened by pressure), then follows the fitting route"
|
|
1100
|
+
},
|
|
1101
|
+
"dynamic_threshold": "idle_hours_max while registered <= live + standing_reserve, otherwise max(idle_hours_min, idle_hours_max / pressure^2)",
|
|
1102
|
+
"never": [
|
|
1103
|
+
"dirty checkouts",
|
|
1104
|
+
"detached or locked checkouts",
|
|
1105
|
+
"admission refusal",
|
|
1106
|
+
"task completion claims",
|
|
1107
|
+
"branch or tag deletion"
|
|
1108
|
+
],
|
|
1109
|
+
"resources": "an unregistered root .venv is registered as reproducible python-venv; release teardown preflight still decides",
|
|
1110
|
+
"physical_removal": "unchanged guarded release and ReleaseReceipt",
|
|
1111
|
+
"admission": "acquire starts a detached pass in its own session and reports CONVERGENCE_SCHEDULED as retention_convergence; it never blocks or slows acquire",
|
|
1112
|
+
"serialization": "applying passes take a non-blocking per-repository host lock; a concurrent pass returns CONVERGENCE_BUSY",
|
|
1113
|
+
"report": "decision.reason and outcome_counts summarize every finding outcome; RELEASED findings carry receipt_id (the ReleaseReceipt) and release_plan_id; ATTENTION_REQUIRED findings carry owner_action",
|
|
1114
|
+
"pass_report": "each applying pass records RUNNING then COMPLETED or FAILED beside the pass lock; a dry run returns it as decision.last_applied_pass, and RUNNING with a free lock reads as INTERRUPTED; it is an observation, never release evidence"
|
|
1115
|
+
},
|
|
1116
|
+
"retained_archive_contract": {
|
|
1117
|
+
"contract": "retained-checkout-archive/v1",
|
|
1118
|
+
"entrypoint": "archive-retained",
|
|
1119
|
+
"plan": "read-only --dry-run binds the exact clean retained checkout, branch, owner and actor",
|
|
1120
|
+
"apply": "requires --plan-id; writes an immutable receipt before CAS transition RETAINED to ARCHIVED",
|
|
1121
|
+
"task_completed": false,
|
|
1122
|
+
"integration_ready": false,
|
|
1123
|
+
"publication_asserted": false,
|
|
1124
|
+
"physical_removal": "separate guarded release/gc-apply; branch and task evidence remain",
|
|
1125
|
+
"compatibility": "ARCHIVED requires retained_archive_version 1; older runtimes fail closed"
|
|
1126
|
+
},
|
|
1127
|
+
"delivered_closeout_contract": {
|
|
1128
|
+
"contract": "delivered-checkout-closeout/v1",
|
|
1129
|
+
"entrypoint": "close-delivered",
|
|
1130
|
+
"plan": "read-only --dry-run binds exact record, HEAD, branch, recorded owner, actor and live publication OID",
|
|
1131
|
+
"apply": "requires --plan-id; writes an immutable closeout receipt before CAS transition RETAINED or legacy PRESERVED to RELEASE_READY",
|
|
1132
|
+
"scope": "clean attached feature/audit checkout with all historical commit evidence in live publication and no lease, runtime, binding, uncleaned resource, frozen handoff or integration obligation",
|
|
1133
|
+
"task_completed": false,
|
|
1134
|
+
"historical_task_evidence": "unchanged; original record retained in the receipt",
|
|
1135
|
+
"physical_removal": "separate existing release/gc-apply, with receipt, runtime and publication revalidation",
|
|
1136
|
+
"compatibility": "RELEASE_READY requires delivered_closeout_version 1; older runtimes fail closed on this lifecycle"
|
|
1137
|
+
},
|
|
1138
|
+
"writer_lease_schema_version": 2,
|
|
1139
|
+
"writer_admission_states": [
|
|
1140
|
+
"GRANTED",
|
|
1141
|
+
"NOT_APPLICABLE",
|
|
1142
|
+
"REFUSED"
|
|
1143
|
+
],
|
|
1144
|
+
"writer_lease_applicability": {
|
|
1145
|
+
"NOT_APPLICABLE": [
|
|
1146
|
+
"canonical",
|
|
1147
|
+
"control-plane",
|
|
1148
|
+
"integration",
|
|
1149
|
+
"preservation",
|
|
1150
|
+
"publication",
|
|
1151
|
+
"recovery",
|
|
1152
|
+
"verification"
|
|
1153
|
+
],
|
|
1154
|
+
"REQUIRED": [
|
|
1155
|
+
"audit",
|
|
1156
|
+
"emergency",
|
|
1157
|
+
"feature",
|
|
1158
|
+
"hotfix"
|
|
1159
|
+
]
|
|
1160
|
+
},
|
|
1161
|
+
"writer_session_actions": [
|
|
1162
|
+
"acquire",
|
|
1163
|
+
"check",
|
|
1164
|
+
"describe",
|
|
1165
|
+
"host-check",
|
|
1166
|
+
"release"
|
|
1167
|
+
],
|
|
1168
|
+
"writer_session_version": 2,
|
|
1169
|
+
"cleanup_hardlink_topology_contract": {
|
|
1170
|
+
"contract": "cleanup-hardlink-topology/v2",
|
|
1171
|
+
"supported_versions": [
|
|
1172
|
+
1,
|
|
1173
|
+
2
|
|
1174
|
+
],
|
|
1175
|
+
"expected_mutations": "cleanup-induced-hardlink-mutation/v2",
|
|
1176
|
+
"closed_topology_encoding": "cleanup-hardlink-topology/v1",
|
|
1177
|
+
"outside_scope": "names never searched or modified; exact external link-count remainder",
|
|
1178
|
+
"evidence": "complete in-scope inode/member/content map; pinned shared inode content and metadata before/after each unlink",
|
|
1179
|
+
"observation_scope": "unlink boundary, not global exclusion of external writers",
|
|
1180
|
+
"unsupported_special_nodes": "BLOCK"
|
|
1181
|
+
},
|
|
1182
|
+
"re_preservation_recovery_contract": {
|
|
1183
|
+
"contract": "re-preservation-recovery/v1",
|
|
1184
|
+
"historical_hardlink_cause": "NOT_PROVEN",
|
|
1185
|
+
"old_evidence": "immutable",
|
|
1186
|
+
"completed_action_replay": false,
|
|
1187
|
+
"new_baseline": "new exact full preservation generation",
|
|
1188
|
+
"terminal": "append-only completion; historical journal retained"
|
|
1189
|
+
},
|
|
1190
|
+
"cleanup_resume_attempt_contract": {
|
|
1191
|
+
"contract": "cleanup-resume-attempt/v1",
|
|
1192
|
+
"reconciliation_contract": "started-no-action-recovery/v1",
|
|
1193
|
+
"states": [
|
|
1194
|
+
"ATTEMPT_STARTED",
|
|
1195
|
+
"ACTION_STARTED",
|
|
1196
|
+
"ACTION_COMPLETED",
|
|
1197
|
+
"ATTEMPT_FAILED_BEFORE_ACTION",
|
|
1198
|
+
"PARTIAL_ACTION",
|
|
1199
|
+
"STARTED_NO_ACTION_RECOVERABLE"
|
|
1200
|
+
],
|
|
1201
|
+
"absent_completion": "immutable underlying refusal; no receipt path constructed",
|
|
1202
|
+
"supersession": "explicit reconcile-attempt, exact filesystem/topology/preservation/runtime validation, new attempt identity",
|
|
1203
|
+
"old_evidence": "immutable; historical refusal not reconstructed"
|
|
1204
|
+
},
|
|
1205
|
+
"typed_cleanup_no_action_contract": {
|
|
1206
|
+
"contract": "typed-cleanup-no-action/v1",
|
|
1207
|
+
"stage": "reconcile-typed",
|
|
1208
|
+
"requires": "exact pending journal, no action evidence, absent receipt or exact pre-action refusal receipt, current scope identity/content, owner/Git/runtime checks",
|
|
1209
|
+
"refusal_receipt": "immutable SHA-256 binding; original failure retained; no action/runtime checkpoint",
|
|
1210
|
+
"external_link_history": "NOT_PROVEN",
|
|
1211
|
+
"terminal": "TYPED_ATTEMPT_SUPERSEDED; original journal unchanged; fresh cleanup required",
|
|
1212
|
+
"automatic_authority": "existing exact approved release intent only"
|
|
1213
|
+
},
|
|
1214
|
+
"metadata_reference_relocation_contract": {
|
|
1215
|
+
"contract": "metadata-reference-relocation/v1",
|
|
1216
|
+
"authority": "explicit governed layout migration only",
|
|
1217
|
+
"binding": [
|
|
1218
|
+
"previous_root",
|
|
1219
|
+
"current_root",
|
|
1220
|
+
"root_device_inode",
|
|
1221
|
+
"relative_evidence_path",
|
|
1222
|
+
"sha256"
|
|
1223
|
+
],
|
|
1224
|
+
"historical_receipts": "byte-identical; no alias namespace",
|
|
1225
|
+
"admitted_transactions": [
|
|
1226
|
+
"exact terminal evidence",
|
|
1227
|
+
"verified tracked-source no-action baseline"
|
|
1228
|
+
],
|
|
1229
|
+
"recovery_execution": "installed Controller only; separate append-only reconciliation",
|
|
1230
|
+
"rollback": "blocked after new or changed cleanup evidence; preserve history",
|
|
1231
|
+
"producers": [
|
|
1232
|
+
"activation_layout.LayoutMigration, which renames the whole namespace and carries the record with it",
|
|
1233
|
+
"namespace_migration.migrate_namespace, which merges a per-repository namespace under the destination lock and writes the record only after the previous root is gone"
|
|
1234
|
+
]
|
|
1235
|
+
},
|
|
1236
|
+
"published_handoff_resource_registration_version": 1,
|
|
1237
|
+
"published_handoff_resource_registration_contract": {
|
|
1238
|
+
"contract": "published-handoff-resource-registration/v1",
|
|
1239
|
+
"command": "resource-register",
|
|
1240
|
+
"target": "HANDOFF_READY hotfix without a pending release intent; existing ignored task-local root .venv only",
|
|
1241
|
+
"owner": "exact recorded owner and record CAS; creator must be handoff-owner-attestation:<owner>, not an asserted original creation command",
|
|
1242
|
+
"identity": "clean attached linked checkout; exact nonempty task/handoff/Finalizer HEAD and record ID; retained branch and original base ancestry; no recovery lineage",
|
|
1243
|
+
"publication": "live policy ls-remote equals tracking ref; exact frozen HEAD and original base are ancestors of publication",
|
|
1244
|
+
"blockers": "writer/publication leases, bindings, managed or observed runtime, scan uncertainty, open integration obligations, unrelated historical source handoff, nonterminal or unknown scoped transactions",
|
|
1245
|
+
"resource": "reproducible on-release python-venv; existing tracking/ignore/type checks and unchanged reproducible teardown preflight",
|
|
1246
|
+
"proof": "append published_handoff_resource_registration to the new DISPOSABLE_REGISTERED history event; preserve old history and frozen fields",
|
|
1247
|
+
"effect": "metadata classification only; no source changes, reopen, cleanup, business completion or new release authority",
|
|
1248
|
+
"release": "existing owner-authorized release rechecks current resource and runtime evidence; automatic convergence roles unchanged"
|
|
1249
|
+
},
|
|
1250
|
+
"typed_cleanup_no_action_version": 1,
|
|
1251
|
+
"typed_cleanup_no_action_receipt_version": 1,
|
|
1252
|
+
"typed_cleanup_verify_boundary_version": 1,
|
|
1253
|
+
"typed_cleanup_verify_boundary_contract": {
|
|
1254
|
+
"boundary": "resource-clean verifies hardlink topology before marking an action STARTED; a topology refusal leaves no action evidence",
|
|
1255
|
+
"legacy_refusal": "a pre-1.28.0 journal whose first action is FAILED_OR_PARTIAL with failure HARDLINK_TOPOLOGY_BLOCKED, later actions PENDING, and only <cleanup-actions>/<transaction>/0000-before.json bound to the plan topology is accepted by reconcile-typed and rollout-check",
|
|
1256
|
+
"receipt": "the refusal receipt may carry exactly one runtime check for the first resource; reconciliation binds the BEFORE receipt as verify_boundary_receipt",
|
|
1257
|
+
"proof": "unchanged typed resource evidence (whole-tree path, device, inode, mode, size and mtime) and exact in-scope inode, member and content topology prove no deletion began",
|
|
1258
|
+
"external_churn": "ctime and nlink drift is accepted only on inodes with links outside the scope before and after; in-scope-only inodes stay exact",
|
|
1259
|
+
"storage_layout_version": 5
|
|
1260
|
+
},
|
|
1261
|
+
"resource_admission_version": 1,
|
|
1262
|
+
"acquire_no_effect_recovery_version": 1,
|
|
1263
|
+
"execution_admission_version": 1,
|
|
1264
|
+
"host_execution_admission_version": 2,
|
|
1265
|
+
"runtime_binding_version": 1,
|
|
1266
|
+
"supported_writer_session_versions": [
|
|
1267
|
+
1,
|
|
1268
|
+
2
|
|
1269
|
+
],
|
|
1270
|
+
"resource_admission_contract": {
|
|
1271
|
+
"contract": "host-resource-admission/v1",
|
|
1272
|
+
"authority": "shared per-user host ledger; repository ownership remains independent",
|
|
1273
|
+
"checkout_counts": "statistics only across all readable policy schemas",
|
|
1274
|
+
"queue": "durable WAITING without a writer; attempted mutations require terminal evidence; positive no-effect recovery archives the original journal before ordinary re-admission",
|
|
1275
|
+
"release": "runtime clearance settles execution; verified allocation release receipts also reconcile historical writer-only reservations",
|
|
1276
|
+
"writer_ownership": "writer grants do not reserve or bind execution; launchers admit before launch and bind existing runtime occupancy",
|
|
1277
|
+
"diagnostics": "writer_leases_recorded counts ownership; runtime_occupied and the live_executions compatibility alias count runtime-bound allocations, not observed process liveness",
|
|
1278
|
+
"pressure": "filesystem bytes/inodes plus growth/preservation; memory budget and CPU/memory/IO PSI hysteresis",
|
|
1279
|
+
"rollback": "target must support every nonterminal request capability",
|
|
1280
|
+
"host_execution_scope": "admission refuses the home root and its ancestors; historical home-scoped rows close only through typed dead-holder recovery",
|
|
1281
|
+
"host_execution_recovery": "read-only inspect publishes the canonical holder bytes, SHA-256 digest, dead-holder observation and terminal-evidence template; typed clear re-verifies every fact and writes one immutable receipt; a provably absent target releases through the same authority as an orphan"
|
|
1282
|
+
},
|
|
1283
|
+
"governance_version": 2,
|
|
1284
|
+
"doctor_mount_version": 2,
|
|
1285
|
+
"governance_contract": {
|
|
1286
|
+
"contract": "worktree-governance/v2",
|
|
1287
|
+
"gc_plan": "read-only classification of all Git registrations; each candidate independently probes its checkout repo path, .git entry, Git common dir and lock path, reporting UNKNOWN for inaccessible mount evidence rather than inheriting another candidate's mount state; each candidate includes candidate_reason, session, lifecycle_observation, stale_facts, orphan_facts, filesystem_health, namespace_health and blocking_facts; --path with owner release or release intent runs ReleasePlan preflight, while an owner-reviewed physically missing no-change audit can produce a registration-prune plan",
|
|
1288
|
+
"gc_apply": "one reviewed target at a time; rechecks plan identity under the repository lock and routes ordinary checkout removal through release with ReleasePlan and ReleaseReceipt; a target already released by exactly the reviewed ReleasePlan returns that receipt as ALREADY_RELEASED after release re-verifies it, while a release by any other plan stays GC_PLAN_DRIFT naming its receipt; or removes only a missing no-change audit registration through a recoverable registration-prune transaction and receipt",
|
|
1289
|
+
"plan_identity": "ordinary release: SHA-256 of canonical JSON ReleasePlan fields excluding timestamped created_at and plan_id; registration prune: SHA-256 of repository, allocation, missing path, admin key, HEAD, owner, record version and preserving publication ref identity; both require no writer or publication lease",
|
|
1290
|
+
"capacity": "observe only: active and retained counts cover feature/audit linked worktrees and use their policy slot limits; total counts all Git registrations and uses hard_limit; no admission change",
|
|
1291
|
+
"lifecycle_observation": "status and gc-plan report recorded owner, lifecycle, session, runtime_sessions, lease, heartbeat, status, stale_facts, orphan_facts, integrity_facts and advisory_only; orphan_observations reports repository-level findings; host session health is UNKNOWN without independent evidence; lease renewal is not an independent heartbeat and observations change no lifecycle, release eligibility or GC authority",
|
|
1292
|
+
"doctor_mounts": "repo, .git entry, Git common dir, existing lock and lock parent are probed in the caller namespace; current and optional namespace.peer report RW, READ_ONLY or UNKNOWN, plus lock_shape, lock_writable and lock_access_errno; --namespace-pid on doctor, status or gc-plan compares a selected process namespace through its root",
|
|
1293
|
+
"status_diagnosis": "successful status responses include mount_diagnostics and environment_diagnosis; on a status failure the CLI retains the classified error code, and doctor is the detailed mount-evidence entry point",
|
|
1294
|
+
"doctor_diagnosis": "mount_diagnostics.environment and top-level environment_diagnosis have code HEALTHY, MOUNT_NAMESPACE_MISMATCH, FILESYSTEM_PERMISSION or UNKNOWN with evidence in facts; doctor decision.primary_diagnosis is MOUNT_NAMESPACE_MISMATCH, FILESYSTEM_PERMISSION, UNKNOWN, CONTROLLER_LOCK_AUTHORITY, CONTROLLER_METADATA or NONE; only known different RW mount vectors establish mismatch, environment faults take precedence over Controller lock attribution, and no diagnostic infers sandbox source or repairs mounts",
|
|
1295
|
+
"storage": "no new metadata documents or directories; existing release plans, receipts and audit remain authoritative"
|
|
1296
|
+
},
|
|
1297
|
+
"branch_retirement_execution_version": 1,
|
|
1298
|
+
"namespace_migration_version": 1,
|
|
1299
|
+
"namespace_migration_contract": {
|
|
1300
|
+
"status": "stable in 1.11.0; namespace-migration/v1 identity is unchanged and runtime replay and evidence checks are hardened after the 1.8.0 audit; storage-layout/v4 declares the already existing registration-prune receipt directory without moving data; no production namespace migration is implied",
|
|
1301
|
+
"open_defects": [],
|
|
1302
|
+
"preflight": "unfinished journals and transactions in either namespace block the transition; the advisory plan defers that question to the fence rather than queueing behind a writer, and reports preflight as under_fence",
|
|
1303
|
+
"authority_switch": "repo.json is the only file that makes a namespace authoritative, so it lands last by rename; the destination copy is re-digested against the prepared identity before and after the switch",
|
|
1304
|
+
"commands": [
|
|
1305
|
+
"namespace-migration-plan",
|
|
1306
|
+
"namespace-migrate",
|
|
1307
|
+
"namespace-migration-receipts",
|
|
1308
|
+
"namespace-migration-verify"
|
|
1309
|
+
],
|
|
1310
|
+
"compatibility": "read-only verbs, retirement plans, receipts and every released contract name are unchanged; the legacy namespace is never discovered at runtime, so an unmigrated repository keeps reporting NAMESPACE_UNMANAGED rather than partial state",
|
|
1311
|
+
"contract": "namespace-migration/v1",
|
|
1312
|
+
"critical_section": {
|
|
1313
|
+
"fence": "an exclusive flock on the destination repo.lock, created before any content lands, is held for the whole transition",
|
|
1314
|
+
"legacy_lock": "held exclusively without waiting; a caller that holds it is an activation in flight, and waiting there would invert that flow's lock order, so the migration fails closed with NAMESPACE_BUSY instead",
|
|
1315
|
+
"not_claimed": "the fence serializes Controller and activation writers only; a process that ignores repo.lock is outside this contract",
|
|
1316
|
+
"why_destination": "adopt, acquire and integration-enqueue bootstrap metadata with create=True under that same lock, so a concurrent verb queues instead of minting a second repository identity beside the tree being moved"
|
|
1317
|
+
},
|
|
1318
|
+
"durability": {
|
|
1319
|
+
"legacy_removal": "directories are removed only when empty and the namespace root only after its lock, so unexplained content fails closed with NAMESPACE_RESIDUE",
|
|
1320
|
+
"per_document": "a document moves only while its planned source bytes match; a complete converted lease is published atomically and an interrupted rewrite leaves only ignored scratch; a destination copy is accepted only when it matches the planned target, except an explicitly planned schema rewrite",
|
|
1321
|
+
"prepared_receipt": "write-once before destructive work; records identity, source/current/target manifest, lease conversions and policy move so replay can use the original CAS after later destination writes",
|
|
1322
|
+
"receipts": "write-once 0400 documents under namespace-migrations/, keyed by plan id; a settled receipt makes an exact replay idempotent and an unsettled prepared receipt is reported for recovery",
|
|
1323
|
+
"relocation_record": "metadata-reference-relocation/v1 evidence is written only after the legacy root is gone, which is when the frozen reference resolver requires the previous root to be absent"
|
|
1324
|
+
},
|
|
1325
|
+
"error_codes": [
|
|
1326
|
+
"NAMESPACE_BUSY",
|
|
1327
|
+
"NAMESPACE_CONFLICT",
|
|
1328
|
+
"NAMESPACE_EVIDENCE_INVALID",
|
|
1329
|
+
"NAMESPACE_IDENTITY_MISMATCH",
|
|
1330
|
+
"NAMESPACE_IDENTITY_MISSING",
|
|
1331
|
+
"NAMESPACE_LEASE_INVALID",
|
|
1332
|
+
"NAMESPACE_LOCK_INVALID",
|
|
1333
|
+
"NAMESPACE_LOCK_MISSING",
|
|
1334
|
+
"NAMESPACE_PATH_INVALID",
|
|
1335
|
+
"NAMESPACE_PLAN_DRIFT",
|
|
1336
|
+
"NAMESPACE_POLICY_DRIFT",
|
|
1337
|
+
"NAMESPACE_RELOCATION_PRESENT",
|
|
1338
|
+
"NAMESPACE_RESIDUE",
|
|
1339
|
+
"NAMESPACE_SOURCE_DRIFT",
|
|
1340
|
+
"NAMESPACE_SOURCE_MISSING",
|
|
1341
|
+
"NAMESPACE_UNMANAGED",
|
|
1342
|
+
"NAMESPACE_UNSAFE",
|
|
1343
|
+
"NAMESPACE_UNSUPPORTED"
|
|
1344
|
+
],
|
|
1345
|
+
"result_codes": [
|
|
1346
|
+
"NAMESPACE_ALREADY_CURRENT",
|
|
1347
|
+
"NAMESPACE_CONVERGED",
|
|
1348
|
+
"NAMESPACE_CONVERGENCE_REQUIRED",
|
|
1349
|
+
"NAMESPACE_MIGRATED",
|
|
1350
|
+
"NAMESPACE_MIGRATION_REQUIRED",
|
|
1351
|
+
"NAMESPACE_RECEIPTS",
|
|
1352
|
+
"NAMESPACE_VERIFIED",
|
|
1353
|
+
"NAMESPACE_VERIFY_FAILED"
|
|
1354
|
+
],
|
|
1355
|
+
"fault_points": [
|
|
1356
|
+
"namespace_receipt_prepared",
|
|
1357
|
+
"namespace_conversion_temp_partial",
|
|
1358
|
+
"namespace_converted_lease_published",
|
|
1359
|
+
"namespace_rewrite_temp_fsynced",
|
|
1360
|
+
"namespace_destination_rewritten",
|
|
1361
|
+
"namespace_entries_moved",
|
|
1362
|
+
"namespace_switched",
|
|
1363
|
+
"namespace_record_written",
|
|
1364
|
+
"namespace_policy_moved",
|
|
1365
|
+
"namespace_receipt_settled"
|
|
1366
|
+
],
|
|
1367
|
+
"identity": {
|
|
1368
|
+
"canonicalization": "sha256 over the canonical JSON encoding of these fields, exactly as preservation._sha encodes them",
|
|
1369
|
+
"compare_and_set": "namespace-migrate refuses unless the caller presents the exact observed plan id; a new transition re-derives it inside the fence, while an unsettled transition replays only from its matching prepared witness",
|
|
1370
|
+
"fields": [
|
|
1371
|
+
"contract",
|
|
1372
|
+
"schema_version",
|
|
1373
|
+
"repository_id",
|
|
1374
|
+
"repository_path",
|
|
1375
|
+
"common_dir",
|
|
1376
|
+
"legacy_root",
|
|
1377
|
+
"current_root",
|
|
1378
|
+
"merged_digest",
|
|
1379
|
+
"policy_target",
|
|
1380
|
+
"policy_sha256"
|
|
1381
|
+
],
|
|
1382
|
+
"plan_id": "SHA-256 of the released identity fields; a prepared receipt preserves the original identity through move, rewrite and later mutable destination writes, and a different requested id is refused"
|
|
1383
|
+
},
|
|
1384
|
+
"previous_namespace": "codex-worktree",
|
|
1385
|
+
"purpose": "the only supported entry for the historical <git-common-dir>/codex-worktree/v1 namespace; callers never copy, edit or delete namespace JSON",
|
|
1386
|
+
"scenarios": {
|
|
1387
|
+
"NAMESPACE_ALREADY_CURRENT": "the legacy namespace is absent and no prepared transition is unsettled; an exact no-op CAS writes no receipt, while a settled transition is reported idempotently through its original receipt",
|
|
1388
|
+
"NAMESPACE_CONFLICT": "both namespaces hold the same path with content that is neither equal nor one document's two schemas; nothing moves and no receipt is written",
|
|
1389
|
+
"NAMESPACE_CONVERGENCE_REQUIRED": "both namespaces hold equivalent content, or the destination holds a document in a form the runtime cannot read; redundant legacy copies clear and the destination is rewritten to the authoritative form",
|
|
1390
|
+
"NAMESPACE_MIGRATION_REQUIRED": "content exists only in the legacy namespace; it moves",
|
|
1391
|
+
"NAMESPACE_UNMANAGED": "neither namespace exists; there is no metadata to migrate"
|
|
1392
|
+
},
|
|
1393
|
+
"recovery": "namespace-migration-plan remains read-only and reports recovery_required plus the original plan id for an unsettled PREPARED receipt; namespace-migrate requires that exact id, checks source and immutable evidence, tolerates post-switch mutable Controller records, and completes relocation evidence and SETTLED receipt without a second transition"
|
|
1394
|
+
},
|
|
1395
|
+
"result_contracts": [
|
|
1396
|
+
"branch-retirement/v1",
|
|
1397
|
+
"branch-retirement/v2",
|
|
1398
|
+
"branch-retirement/v5",
|
|
1399
|
+
"namespace-migration/v1",
|
|
1400
|
+
"re-preservation-recovery/v1",
|
|
1401
|
+
"worktree-controller/v1",
|
|
1402
|
+
"worktree-governance/v1",
|
|
1403
|
+
"worktree-governance/v2",
|
|
1404
|
+
"writer-admission/v1",
|
|
1405
|
+
"closed-lifecycle/v1",
|
|
1406
|
+
"release-recovery-inspection/v1",
|
|
1407
|
+
"integration-publication-session/v1"
|
|
1408
|
+
],
|
|
1409
|
+
"document_contracts": [
|
|
1410
|
+
"branch-retirement-execution/v1",
|
|
1411
|
+
"branch-retirement/v5",
|
|
1412
|
+
"controller-transaction-conflict/v1",
|
|
1413
|
+
"metadata-reference-relocation/v1",
|
|
1414
|
+
"namespace-migration/v1",
|
|
1415
|
+
"retirement-execution-result/v1",
|
|
1416
|
+
"storage-layout/v1",
|
|
1417
|
+
"integration-publication-session/v1",
|
|
1418
|
+
"no-change-cleanup-closeout/v1"
|
|
1419
|
+
],
|
|
1420
|
+
"closed_lifecycle_query_version": 1,
|
|
1421
|
+
"closed_lifecycle_query_contract": {
|
|
1422
|
+
"contract": "closed-lifecycle/v1",
|
|
1423
|
+
"query_version": 1,
|
|
1424
|
+
"selectors": [
|
|
1425
|
+
"allocation_id",
|
|
1426
|
+
"authority_key",
|
|
1427
|
+
"task_key",
|
|
1428
|
+
"integration_intent_id",
|
|
1429
|
+
"release_receipt_id"
|
|
1430
|
+
],
|
|
1431
|
+
"selector_count": 1,
|
|
1432
|
+
"default_limit": 100,
|
|
1433
|
+
"maximum_limit": 1000,
|
|
1434
|
+
"cursor": "exclusive immutable release_receipt_id in ascending lexical order",
|
|
1435
|
+
"sources": [
|
|
1436
|
+
"records",
|
|
1437
|
+
"release-plans",
|
|
1438
|
+
"release-receipts",
|
|
1439
|
+
"release-intents",
|
|
1440
|
+
"integration-intents",
|
|
1441
|
+
"prepared-candidate-receipts",
|
|
1442
|
+
"publication-receipts"
|
|
1443
|
+
],
|
|
1444
|
+
"live_field": "live_allocations",
|
|
1445
|
+
"historical_field": "closed_releases",
|
|
1446
|
+
"missing_receipt_field": "incomplete_history",
|
|
1447
|
+
"owner_authority": "immutable release plan at closure, never an integration publisher or current checkout owner",
|
|
1448
|
+
"task_authority": "existing release intent, otherwise retained allocation record",
|
|
1449
|
+
"publication_authority": "immutable publication receipt source_results; join source allocation and exact frozen source handoff independently of mutable integration intent",
|
|
1450
|
+
"semantics": "checkout release proves resource closure, not publication or business completion; no history backfill, mutation, remote access, database, or daemon",
|
|
1451
|
+
"unavailable_evidence": "null or INCOMPLETE; contradictory linked identities fail HISTORY_EVIDENCE_CONFLICT",
|
|
1452
|
+
"storage_layout_version": 4
|
|
1453
|
+
},
|
|
1454
|
+
"source_release_summary_version": 1,
|
|
1455
|
+
"source_release_summary_contract": {
|
|
1456
|
+
"version": 1,
|
|
1457
|
+
"field": "source_release_trigger.outcomes",
|
|
1458
|
+
"entrypoints": ["lease-complete", "reconcile receipts"],
|
|
1459
|
+
"preserved_fields": ["created_intent_ids", "skipped", "reconciliation"],
|
|
1460
|
+
"outcome_fields": ["allocation_id", "status", "result", "blocker"],
|
|
1461
|
+
"completed_result": "ALREADY_RELEASED",
|
|
1462
|
+
"completed_evidence": ["release_receipt_id", "plan_id", "intent_id", "proof_status"],
|
|
1463
|
+
"completion_precondition": "unique COMPLETE closed lifecycle evidence matching frozen source branch, handoff and Finalizer identity, current publication association, and no live binding",
|
|
1464
|
+
"nonterminal_recovery_field": "recovery_commands",
|
|
1465
|
+
"semantics": "checkout closure observation only; no new release authority or historical mutation; live release reconciliation retains its original status, result and blocker"
|
|
1466
|
+
},
|
|
1467
|
+
"tracked_source_progress_recovery_version": 1,
|
|
1468
|
+
"tracked_source_progress_recovery_contract": {
|
|
1469
|
+
"contract": "tracked-source-progress-recovery/v1",
|
|
1470
|
+
"entrypoint": "python -m worktree_controller.source_recovery",
|
|
1471
|
+
"commands": [
|
|
1472
|
+
"plan-progress",
|
|
1473
|
+
"reconcile-progress"
|
|
1474
|
+
],
|
|
1475
|
+
"precondition": "proper recorded restore prefix with a nonempty preserved remainder, complete before/after/check chain, current restored bytes/inodes and preserved remainder, HEAD/index/parents/generation/runtime authority PASS",
|
|
1476
|
+
"terminal_attempt_state": "SOURCE_ATTEMPT_PRESERVED",
|
|
1477
|
+
"started_action": "current baseline match only; historical status remains ACTION_STARTED",
|
|
1478
|
+
"marker": "source-cleanup/<transaction>/progress-reconciliation.json",
|
|
1479
|
+
"source_action": "none",
|
|
1480
|
+
"lifecycle_action": "none",
|
|
1481
|
+
"index_action": "none",
|
|
1482
|
+
"release_authorized": false,
|
|
1483
|
+
"successor_authorized": false,
|
|
1484
|
+
"old_evidence": "retained byte-identical",
|
|
1485
|
+
"rollout": "only verified terminal evidence; unresolved partial attempt remains BLOCK",
|
|
1486
|
+
"rollback": "unaware runtimes remain blocked by existing rollout gate"
|
|
1487
|
+
},
|
|
1488
|
+
"multiple_preservation_cleanup_version": 1,
|
|
1489
|
+
"multiple_preservation_cleanup_contract": {
|
|
1490
|
+
"contract": "legacy-preserved-state-multiple-cleanup/v1",
|
|
1491
|
+
"command": "resource-clean --typed",
|
|
1492
|
+
"primary_options": [
|
|
1493
|
+
"--preservation-receipt",
|
|
1494
|
+
"--preservation-receipt-sha256"
|
|
1495
|
+
],
|
|
1496
|
+
"additional_options": [
|
|
1497
|
+
"--additional-preservation-receipt",
|
|
1498
|
+
"--additional-preservation-receipt-sha256"
|
|
1499
|
+
],
|
|
1500
|
+
"input": "primary pair plus equally sized repeatable additional pairs; reject duplicate receipts, overlapping source paths or any invalid coverage",
|
|
1501
|
+
"identity": "all normalized source-relative proof rows and per-resource evidence are bound by plan_id, journal and immutable receipt",
|
|
1502
|
+
"guards": "existing allocation, owner/CAS, Git, all-resource, runtime, lease, binding, retained-ref and source-cleanup gates remain mandatory",
|
|
1503
|
+
"source_verification": "each action rechecks its own coverage and full hardlink topology; only previously COMPLETED source paths may use destination-only coverage and must remain absent",
|
|
1504
|
+
"release": "all actions completed and every preserved source absent with every immutable generation verified against exact allocation identity",
|
|
1505
|
+
"interrupted_recovery": "prepare-multiple with exact original journal/receipt SHA-256; completed prefix and never-started pending suffix only; full original proof set and immutable historical evidence retained",
|
|
1506
|
+
"single_input_compatibility": "existing single receipt contract, plan and receipt shape remain unchanged",
|
|
1507
|
+
"storage_layout_version": 4
|
|
1508
|
+
},
|
|
1509
|
+
"retained_typed_cleanup_version": 1,
|
|
1510
|
+
"aborted_integration_preserved_cleanup_version": 1,
|
|
1511
|
+
"aborted_integration_preserved_cleanup_contract": {
|
|
1512
|
+
"contract": "aborted-integration-preserved-cleanup/v1",
|
|
1513
|
+
"entrypoints": ["integration-abort", "python -m worktree_controller.preservation", "resource-clean --typed", "release", "integration-claim"],
|
|
1514
|
+
"eligible": "unpublished integration allocation in INTEGRATION_ABORTED with exact owner, HEAD, record CAS and retained branch; every removed tree has exact immutable preservation coverage",
|
|
1515
|
+
"quarantine": "direct cleanup stays refused; only the existing explicit owner/CAS integration-abort transition may abort a quarantined candidate, preserving quarantine and failure history",
|
|
1516
|
+
"abort_identity": "new abort history pins receipt ID and raw SHA-256; legacy single exact matching receipt remains supported; missing, changed or ambiguous evidence blocks",
|
|
1517
|
+
"generated_paths": "no Astro or directory-name allowlist; ignored and untracked does not mean disposable; even recognized disposable trees require preservation in this lifecycle",
|
|
1518
|
+
"lease_and_runtime": "any recorded writer lease including expired, publication authority, bindings, managed runtime, uncertain scans and unresolved transactions block; no lease is reclaimed here",
|
|
1519
|
+
"admission": "request identity and reservation stay unchanged until guarded allocation release; only verified release evidence settles the old budget before a changed-source intent can be claimed",
|
|
1520
|
+
"source_identity": "unchanged-source retries keep their existing retry contract; changed sources require their own frozen reviewed intent, never source replacement or queue priority inheritance",
|
|
1521
|
+
"repeat": "consumed live-source preservation inputs remain refused; a fresh empty cleanup plan verifies completed receipts without deletion; guarded release has its existing exact-request replay",
|
|
1522
|
+
"result": "cleanup only; never publication, source adoption, branch retirement or task completion",
|
|
1523
|
+
"storage_layout_version": 5
|
|
1524
|
+
},
|
|
1525
|
+
"multiple_preservation_recovery_version": 1,
|
|
1526
|
+
"multiple_preservation_recovery_contract": {
|
|
1527
|
+
"contract": "multiple-preservation-cleanup-recovery/v1",
|
|
1528
|
+
"stages": ["prepare-multiple", "resume"],
|
|
1529
|
+
"input": "exact original transaction id, journal SHA-256, failed completion receipt SHA-256, owner, path and record CAS",
|
|
1530
|
+
"precondition": "nonempty exact completed action prefix and nonempty never-started pending suffix; all before/after action references and topology transitions verified; no suffix action evidence",
|
|
1531
|
+
"proof_set": "entire original normalized preservation evidence set; no single-receipt downgrade or omitted generation",
|
|
1532
|
+
"historical_metadata": "immutable recovery record freezes the exact allocation owner/CAS/history and complete verified official generation metadata references with raw SHA-256; terminal verification rechecks their unchanged complete set, including older superseded generations",
|
|
1533
|
+
"released_checkout": "absence is accepted only with exact official release plan, receipt and frozen allocation history; live source/root/ancestor and deletion guards remain unchanged",
|
|
1534
|
+
"execution": "existing guarded cleanup runner uses a new transaction UUID for the pending suffix; completed prefix never replayed",
|
|
1535
|
+
"guards": "exact allocation, owner, HEAD, record CAS, branch, root and ancestor identities, preserved generations, all resources, topology, Git, retained refs, runtime, leases, bindings and transaction authority",
|
|
1536
|
+
"terminal": "append-only exact composite of the original completed prefix and successful successor action chain; original journal and failed receipt remain byte-identical",
|
|
1537
|
+
"interrupted_successor": "never replay a started suffix attempt; only exact successful completion may finish a missing terminal receipt",
|
|
1538
|
+
"rollback": "unaware runtimes remain blocked through the retained original multi cleanup journal",
|
|
1539
|
+
"storage_layout_version": 4
|
|
1540
|
+
},
|
|
1541
|
+
"preservation_supersession_version": 1,
|
|
1542
|
+
"preservation_supersession_contract": {
|
|
1543
|
+
"authority": "one exact allocation and owner with verified frozen handoff, formal reopen and new frozen handoff history",
|
|
1544
|
+
"baseline": "same source-relative path and original root/ancestor chain; fully verified current preservation plus actual completed action may cover older generations through the formal lineage",
|
|
1545
|
+
"old_evidence": "every official generation metadata is verified and retained; absence alone grants no cleanup authority"
|
|
1546
|
+
},
|
|
1547
|
+
"retained_typed_cleanup_contract": {
|
|
1548
|
+
"command": "resource-clean --typed",
|
|
1549
|
+
"eligible_lifecycle": "RETAINED",
|
|
1550
|
+
"eligible_roles": [
|
|
1551
|
+
"feature",
|
|
1552
|
+
"audit"
|
|
1553
|
+
],
|
|
1554
|
+
"preservation_admission": "exact allocation, owner, HEAD and record CAS; retained ref and lineage required",
|
|
1555
|
+
"cleanup_input": "existing primary and paired additional preservation receipt options; no second composition family",
|
|
1556
|
+
"guards": "existing cleanliness, writer, runtime, binding, all-resource, integration and transaction gates remain mandatory",
|
|
1557
|
+
"result": "cleanup only; task completion, archival and physical release remain separate",
|
|
1558
|
+
"archive_evidence": "freeze actual completed cleanup receipt IDs, paths and raw SHA256 values",
|
|
1559
|
+
"release_bridge": "verified archive before-record identity to after-record CAS exactly +1; reverify frozen immutable receipts",
|
|
1560
|
+
"partial_failure": "preserve original journal and immutable receipt; no multi replay or downgrade"
|
|
1561
|
+
},
|
|
1562
|
+
"preservation_leaf_version": 1,
|
|
1563
|
+
"no_change_cleanup_closeout_version": 1,
|
|
1564
|
+
"no_change_cleanup_closeout_contract": {
|
|
1565
|
+
"contract": "no-change-cleanup-closeout/v1",
|
|
1566
|
+
"future_completion": "complete-no-change freezes the exact before-record, complete transition event and successful cleanup receipt ID/path/raw-SHA256 set; one normal +1 transition pins its write-once completion receipt",
|
|
1567
|
+
"recovery_entrypoint": "reconcile no-change-completion",
|
|
1568
|
+
"recovery_inputs": "exact path, owner, original completion CAS, completion receipt ID/raw SHA256 and repeatable paired successful cleanup receipt IDs/raw SHA256; dry-run plus expected-plan-id",
|
|
1569
|
+
"legacy": "one unique old no-change completion and its exact original +1 transition; append-only recovery adds one normal +1 history event, never rewrites old evidence or replays deletion",
|
|
1570
|
+
"replay": "while the checkout remains registered, the same original request returns the same receipt without another CAS transition; changed identity or additional history fails closed; after release use normal release replay or exact lifecycle-history",
|
|
1571
|
+
"release": "reverify every frozen raw byte digest and derive the full original record through exact transitions before applying unchanged exact-CAS cleanup verification",
|
|
1572
|
+
"guards": "all Git, owner, role, lineage, lease, binding, runtime, editable, resource and scoped transaction guards remain mandatory",
|
|
1573
|
+
"storage_layout_version": 4
|
|
1574
|
+
},
|
|
1575
|
+
"preservation_leaf_contract": {
|
|
1576
|
+
"preservation_contract": "legacy-preserved-state/v1",
|
|
1577
|
+
"entrypoint": "python -m worktree_controller.preservation",
|
|
1578
|
+
"source_kinds": [
|
|
1579
|
+
"directory",
|
|
1580
|
+
"regular-file",
|
|
1581
|
+
"literal-symlink"
|
|
1582
|
+
],
|
|
1583
|
+
"scope": "selected exact ignored source-relative path; no tracked parent or sibling removal",
|
|
1584
|
+
"identity": "original source and full ancestor identities bound to immutable plan and verified immediately before cleanup",
|
|
1585
|
+
"symlink": "preserve literal link text; never follow or remove its destination",
|
|
1586
|
+
"failure": "unsupported callbacks and changed ancestor, source, environment or hardlink identity fail closed",
|
|
1587
|
+
"cleanup_authorized_by_copy": false
|
|
1588
|
+
},
|
|
1589
|
+
"integration_publication_execution_version": 1,
|
|
1590
|
+
"integration_publication_execution_contract": {
|
|
1591
|
+
"contract": "integration-publication-session/v1",
|
|
1592
|
+
"version": 1,
|
|
1593
|
+
"command": "publication-execution-session",
|
|
1594
|
+
"framing": "UTF-8 JSON lines; this command does not emit the ordinary status envelope",
|
|
1595
|
+
"maximum_frame_bytes": 65536,
|
|
1596
|
+
"idle_timeout_seconds": 300,
|
|
1597
|
+
"response_phases": [
|
|
1598
|
+
"verified",
|
|
1599
|
+
"authorized",
|
|
1600
|
+
"completed",
|
|
1601
|
+
"blocked"
|
|
1602
|
+
],
|
|
1603
|
+
"request_actions": [
|
|
1604
|
+
"authorize",
|
|
1605
|
+
"complete"
|
|
1606
|
+
],
|
|
1607
|
+
"identity_fields": [
|
|
1608
|
+
"repository_id",
|
|
1609
|
+
"allocation_id",
|
|
1610
|
+
"lease_id",
|
|
1611
|
+
"run_id",
|
|
1612
|
+
"remote",
|
|
1613
|
+
"target_ref",
|
|
1614
|
+
"candidate_oid",
|
|
1615
|
+
"expected_main_oid",
|
|
1616
|
+
"validation_evidence_id",
|
|
1617
|
+
"record_version",
|
|
1618
|
+
"expires_at"
|
|
1619
|
+
],
|
|
1620
|
+
"authorization_actions": [
|
|
1621
|
+
"PUSH_CANDIDATE",
|
|
1622
|
+
"RECOVER_ALREADY_PUBLISHED"
|
|
1623
|
+
],
|
|
1624
|
+
"completion_result_fields": [
|
|
1625
|
+
"record_id",
|
|
1626
|
+
"executor",
|
|
1627
|
+
"push_executed",
|
|
1628
|
+
"remote_oid"
|
|
1629
|
+
],
|
|
1630
|
+
"executor_fields": [
|
|
1631
|
+
"name",
|
|
1632
|
+
"version"
|
|
1633
|
+
],
|
|
1634
|
+
"lock_owner": "Controller; one exclusive repository lock spans verify, authorize, consumer push and producer completion observation",
|
|
1635
|
+
"completion": "Controller reobserves the exact remote candidate and returns execution evidence; lease-complete persists the existing publication receipt and owns lifecycle/lease/release changes",
|
|
1636
|
+
"recovery": "Reuse the same candidate, lease and run; an already-published candidate is observed without another push, including after lease expiry",
|
|
1637
|
+
"failure": "Missing authority, protocol drift, disconnect, timeout or an unverified remote fails closed; observe the live remote before retrying an interrupted mutation",
|
|
1638
|
+
"threat_model": "Trusted local caller and OS; no claim of protection from arbitrary same-UID process interference"
|
|
1639
|
+
},
|
|
1640
|
+
"integration_retry_version": 1,
|
|
1641
|
+
"integration_retry_contract": {
|
|
1642
|
+
"contract": "integration-retry/v1",
|
|
1643
|
+
"admission": "exact owner, ATTENTION_REQUIRED, aborted candidate with complete release proof, no publication or active authority, unchanged frozen source/scope",
|
|
1644
|
+
"plan": "read-only dry-run plus expected-plan-id CAS binds failed intent, immutable failure evidence, source records, remote-tracking main and queue evidence",
|
|
1645
|
+
"retry": "reuse original intent ID, source, scope and enqueue sequence; increment attempt, clear old candidate validation and re-enter normal preparation, validation and publication",
|
|
1646
|
+
"prerequisite": "one unclaimed later intent with strict source-ancestor proof may inherit the failed parent scheduling position; immutable queue sequences and independent scope remain unchanged; formal prerequisite publication/release precedes retry",
|
|
1647
|
+
"evidence": "append-only intent history retains the full old failure/abort/release evidence and prior candidate identities; no rewrite or second tracker",
|
|
1648
|
+
"storage_layout_version": 4
|
|
1649
|
+
},
|
|
1650
|
+
"integration_conflict_resolution_version": 2,
|
|
1651
|
+
"integration_conflict_resolution_contract": {
|
|
1652
|
+
"contract": "integration-conflict-resolution/v2",
|
|
1653
|
+
"retry": "integration-retry also accepts exact unallocated INTEGRATION_CONFLICT_BLOCKED history; original owner/source/scope/queue and plan CAS remain mandatory",
|
|
1654
|
+
"retried_attempts": "v2 judges the attempt after the last PREPARATION_RETRY_QUEUED: it must be unclaimed, every earlier claimed attempt must have ended in PREPARATION_ABORTED, and only RELEASED earlier candidates may remain",
|
|
1655
|
+
"claim": "integration-claim --intent-id ID --resolve-conflicts verifies an actual single-source conflict, honors queue/capacity and allocates the pinned main with a pending frozen merge identity",
|
|
1656
|
+
"resolution": "caller resolves only frozen scope and commits via Finalizer; integration-resolve requires exact owner/record/head, clean checkout, exact main/source merge parents and unchanged source evidence",
|
|
1657
|
+
"validation": "resolution only binds a new candidate revision; fresh tests, Snapshot, integration-validate, live-main publication CAS and release remain mandatory",
|
|
1658
|
+
"failure": "unknown failures, wrong owner, stale plan, live candidates, source drift, extra parents/commits, dirty checkout and out-of-scope changes fail closed",
|
|
1659
|
+
"storage_layout_version": 4
|
|
1660
|
+
},
|
|
1661
|
+
"exited_holder_release_version": 1,
|
|
1662
|
+
"exited_holder_release_contract": {
|
|
1663
|
+
"contract": "exited-holder-release/v1",
|
|
1664
|
+
"command": "writer-lease-release with the exact recorded holder identity and --lease-id",
|
|
1665
|
+
"applies_to": "a lease whose holder process has exited (for example reaped by a runtime), whose process group has no surviving member and whose checkout no other process (besides the caller and its ancestors) still uses",
|
|
1666
|
+
"result": "WRITER_LEASE_RELEASED with holder_exited true; allocation lifecycle and work are untouched",
|
|
1667
|
+
"refusals": "a missing or different lease ID, a different identity, surviving children or another process in the checkout keep the lease (WRITER_LEASE_MISMATCH)"
|
|
1668
|
+
},
|
|
1669
|
+
"session_admission_version": 1,
|
|
1670
|
+
"session_admission_contract": {
|
|
1671
|
+
"contract": "session-admission/v1",
|
|
1672
|
+
"admit": "session-admit runs plan, acquire and execution-admit in one process for a new feature allocation from the canonical checkout; any other start returns SESSION_ADMISSION_FALLBACK without changes",
|
|
1673
|
+
"bind": "session-bind runs writer-lease-acquire for the exact live holder, the holder-aware write-guard and the runtime binding add in one process; a later Controller or filesystem error attempts to release the granted lease and reports lease_outcome; failed release retains the exact lease and holder identity for recovery",
|
|
1674
|
+
"guards": "each step is the existing command's function with unchanged guards, journals, receipts and record-version CAS; only the intermediate repository status is omitted",
|
|
1675
|
+
"convergence": "the admission-triggered detached retention pass starts after admission and is skipped while a pass runs or within 300 seconds of the last started pass",
|
|
1676
|
+
"fallback": "hosts without this capability, or on SESSION_ADMISSION_FALLBACK, use the individual commands",
|
|
1677
|
+
"storage_layout_version": 4
|
|
1678
|
+
},
|
|
1679
|
+
"archived_codex_binding_recovery_version": 1,
|
|
1680
|
+
"archived_codex_binding_recovery_contract": {
|
|
1681
|
+
"contract": "archived-codex-binding-recovery/v1",
|
|
1682
|
+
"operation": "binding-remove",
|
|
1683
|
+
"opt_in": "--recover-archived-codex-session",
|
|
1684
|
+
"dry_run": true,
|
|
1685
|
+
"requirements": [
|
|
1686
|
+
"exact owner and record CAS",
|
|
1687
|
+
"released writer lease",
|
|
1688
|
+
"native socket peer matches recorded shared daemon",
|
|
1689
|
+
"exact archived thread notLoaded and absent from loaded list",
|
|
1690
|
+
"no remaining checkout references or associated uncertainty"
|
|
1691
|
+
],
|
|
1692
|
+
"preserves": [
|
|
1693
|
+
"other native threads",
|
|
1694
|
+
"shared daemon",
|
|
1695
|
+
"source files",
|
|
1696
|
+
"lifecycle and owner",
|
|
1697
|
+
"ordinary dead-holder gate"
|
|
1698
|
+
],
|
|
1699
|
+
"receipt": "immutable native-session-recoveries evidence"
|
|
1700
|
+
},
|
|
1701
|
+
"session_closeout_report_version": 1,
|
|
1702
|
+
"session_closeout_expectations_version": 1,
|
|
1703
|
+
"recovery_guidance_version": 1,
|
|
1704
|
+
"recovery_guidance_contract": {
|
|
1705
|
+
"contract": "recovery-guidance/v1",
|
|
1706
|
+
"entrypoint": "recovery-guide --path <checkout> | --intent-id <original-intent>",
|
|
1707
|
+
"observation": "shared repository lock; exact current allocation/owner/task/authority/path/branch/HEAD/CAS and original intent identity",
|
|
1708
|
+
"authority": "read-only; execution_authority=false, execution_guards_checked=false, mutation_performed=false; no eligibility, business completion or publication assertion",
|
|
1709
|
+
"steps": "next_steps[].argv is a structured argument list for only the next observed formal step; reobserve_after_each_step=true; never predict future CAS or compute a consumer digest",
|
|
1710
|
+
"blocked": "clean unchanged BLOCKED integration -> quarantine -> reobserve QUARANTINED -> formal abort -> guarded release dry-run -> exact cleanup/release proof -> original intent retry dry-run/public plan_id -> normal claim/conflict resolution/fresh validation",
|
|
1711
|
+
"terminal": "a published RELEASED intent requires complete matching immutable release and REMOTE_VERIFIED publication evidence; terminal_status=PUBLISHED_RELEASED offers only lifecycle-history inspection, never retry or business completion; incomplete or drifted evidence stays blocked",
|
|
1712
|
+
"fences": "dirty/unknown files, recorded writer/publication leases, bindings, transaction obligations and source/scope/HEAD drift never authorize cleanup or an alternate request; diagnostic warnings remain observations",
|
|
1713
|
+
"doctor": "PASS proves metadata integrity, not lifecycle or publication eligibility"
|
|
1714
|
+
},
|
|
1715
|
+
"session_closeout_expectations_contract": {
|
|
1716
|
+
"entrypoint": "worktree-session-end with the full client/session/holder/run selector and repeatable --expected-allocation-id <uuid>",
|
|
1717
|
+
"coverage": "inspect all exact-selector and prior observed allocations; expected IDs add proof obligations and never select mutation targets; missing expected IDs settle only through complete matching immutable release proof, otherwise remain pending",
|
|
1718
|
+
"results": "expected_allocations joins allocations and previous_allocations in summary; every pending live row has recovery_argv; task_completed remains false",
|
|
1719
|
+
"safety": "reobserve identity and record CAS; retained checkpoint/handoff observations with a new writer lease cannot report terminal_complete; --check remains read-only and strict exits remain 2 until complete",
|
|
1720
|
+
"compatibility": "additive capability; existing selector, advisory exit, CLI 60 and storage 5 remain compatible"
|
|
1721
|
+
},
|
|
1722
|
+
"hosted_session_closeout_check_version": 1,
|
|
1723
|
+
"checkout_owner_action_version": 1,
|
|
1724
|
+
"task_checkpoint_park_version": 1,
|
|
1725
|
+
"binding_registration_backfill_version": 1,
|
|
1726
|
+
"binding_registration_backfill_contract": {
|
|
1727
|
+
"contract": "binding-registration-backfill/v1",
|
|
1728
|
+
"entrypoint": "reconcile binding-registrations",
|
|
1729
|
+
"dry_run": "--dry-run lists candidates, refused bindings with typed blockers and a plan_id; apply requires --expected-plan-id equal to the current plan",
|
|
1730
|
+
"selection": "live linked bindings without a worktree-registration/v1 document; canonical, orphan and already registered bindings are never touched",
|
|
1731
|
+
"requirements": [
|
|
1732
|
+
"record exists",
|
|
1733
|
+
"administrative directory is a real directory whose name derives the binding key",
|
|
1734
|
+
"no pre-existing registration marker",
|
|
1735
|
+
"Git gitdir pointer names the observed checkout",
|
|
1736
|
+
"Git registration (commondir mtime) is no later than record created_at plus 900 seconds",
|
|
1737
|
+
"record base_commit, when present, is an ancestor of the checkout HEAD"
|
|
1738
|
+
],
|
|
1739
|
+
"writes": "the existing worktree-registration/v1 marker and binding-registrations document per candidate; no record, binding, lifecycle or history change",
|
|
1740
|
+
"refused": "refused bindings keep their legacy meaning and are reported for owner review",
|
|
1741
|
+
"storage_layout_version": 5
|
|
1742
|
+
},
|
|
1743
|
+
"session_closeout_report_contract": {
|
|
1744
|
+
"contract": "session-closeout/v1",
|
|
1745
|
+
"entrypoint": "worktree-session-end",
|
|
1746
|
+
"prepare": "--check is read-only and requires the exact client/session/holder and optional recorded run",
|
|
1747
|
+
"strict": "--check and --require-complete return 2 unless selection is complete and every allocation reports terminal_complete",
|
|
1748
|
+
"advisory": "default exit remains 0; SESSION_ENDED is not a success assertion",
|
|
1749
|
+
"summary": [
|
|
1750
|
+
"selected",
|
|
1751
|
+
"complete",
|
|
1752
|
+
"pending",
|
|
1753
|
+
"terminal_complete",
|
|
1754
|
+
"task_completed"
|
|
1755
|
+
],
|
|
1756
|
+
"task_completed": false,
|
|
1757
|
+
"run_identity": "--run-id matches exactly; omission matches only a null run, never a replacement run",
|
|
1758
|
+
"unknown_files": "preserved; dirty or unclassified retained files produce an owner action",
|
|
1759
|
+
"retry": "original selected allocations are persisted as observations before lease release; previous_allocations is read-only and never grants authority; unresolved results remain pending across retries"
|
|
1760
|
+
},
|
|
1761
|
+
"checkout_owner_action_contract": {
|
|
1762
|
+
"contract": "checkout-owner-action/v1",
|
|
1763
|
+
"surfaces": [
|
|
1764
|
+
"status.worktrees[].owner_action_request",
|
|
1765
|
+
"reconcile retention.decision.findings[].owner_action_request",
|
|
1766
|
+
"session-end.allocations[].owner_action"
|
|
1767
|
+
],
|
|
1768
|
+
"identity": [
|
|
1769
|
+
"allocation_id",
|
|
1770
|
+
"task_key",
|
|
1771
|
+
"authority_key",
|
|
1772
|
+
"owner",
|
|
1773
|
+
"expected_record_version",
|
|
1774
|
+
"path",
|
|
1775
|
+
"branch",
|
|
1776
|
+
"head",
|
|
1777
|
+
"action_id"
|
|
1778
|
+
],
|
|
1779
|
+
"consumer": "match an existing Task binding, re-observe the full identity and CAS, and restore only that owner through normal Controller admission",
|
|
1780
|
+
"execution_authority": false,
|
|
1781
|
+
"automatic_discard": false
|
|
1782
|
+
},
|
|
1783
|
+
"task_checkpoint_park_contract": {
|
|
1784
|
+
"entrypoint": "park --checkpoint-id <art_sha256|sha256:hex> --checkpoint-head <oid> [--waiting-on <dependency>]",
|
|
1785
|
+
"source": "content-addressed checkpoint persisted by the existing Task; owner attestation, not content verification or task completion",
|
|
1786
|
+
"guards": "exact owner/record CAS/HEAD, no writer lease or binding; ACTIVE or already RETAINED feature/audit only",
|
|
1787
|
+
"retention": "history records the checkpoint reference; status exposes wait_checkpoint while RETAINED",
|
|
1788
|
+
"release": "explicit reviewed archive-retained plan then unchanged guarded release; branches kept, unknown files block",
|
|
1789
|
+
"resume": "the Task restores the exact retained HEAD through controlled admission and revalidates context before a new writer"
|
|
1790
|
+
}
|
|
1791
|
+
}
|