M12.4: preserve exact biology across ownership candidates
Foundation / checks (deploy) (push) Successful in 5s
Foundation / checks (ecs) (push) Successful in 2m18s
Foundation / postgres-tools (push) Canceled after 0s
Foundation / server-image (push) Canceled after 0s
Foundation / image (push) Canceled after 0s
Foundation / checks (checks) (push) Canceled after 5m33s
Foundation / checks (postgres) (push) Canceled after 5m29s
Foundation / checks (tsan) (push) Canceled after 5m28s
Foundation / checks (client) (push) Canceled after 5m37s
Foundation / checks (network) (push) Canceled after 5m39s

This commit is contained in:
dingo
2026-10-17 18:17:59 -04:00
parent 0a8962b57e
commit decd4f8043
27 changed files with 1408 additions and 61 deletions
@@ -0,0 +1,85 @@
# ADR-0144: Exact wildlife ownership transfer and boundary accounting
## Status
Accepted for a scoped M12.4 engineering primitive, 2026-10-17. Portable candidates
are implemented and locally qualified; durable escrow remains open. This accepts exact ownership/accounting support,
not automatic migration, a linked world atlas or production enablement. Existing
rules-8 arenas and every retained format remain unchanged by default.
## Context and conflict
The current owner deliberately validates a closed regional budget, requires every
archived organism to be a local life/corpse, and admits bud identities only below
its own region's counter. Removing a migrant would violate those contracts;
importing one would also violate the destination's namespace and funding closure.
Recording departure as death, renumbering the organism, rebasing the opening stock
or copying a probe inventory would lose biological identity or conservation.
Resolve this boundary before expanding transfer code. Add a separately versioned
owner representation with explicit boundary flows and nonresident history. The
unchanged general biological kernel continues to operate on resident cells only.
## Decision and scope
Introduce cellular owner format 7 for rules 8, and population envelope 2 containing
it. Upgrading from format 6 is explicit and no-tick: original opening stock,
nursery, habitat, heat, bodies, reserves, identities, archives, positions and timers
are preserved; inbound/outbound flows are zero and nonresident history is empty.
Retain format 6/envelope 1 readers and old biological traces. Do not replace goldens.
The new conservation equation is channel-wise `opening + inbound = current +
outbound`, with checked arithmetic. `current` still counts only actual owned
compartments, including heat. Boundary flows are immutable cumulative accounting
evidence, never spendable resource accounts or an extra copy of biomass. Refuse
overflow/capacity exhaustion; no clamping, debt forgiveness or automatic reset.
A portable transfer prepares two detached candidates from exact compatible cuts:
same world, frame, fixed tick, rules, dimensions and ambient convention; distinct
regions. Move a whole eligible zero-account wildlife genome group. Controlled
cells remain excluded and fully suspended during unattended transfer work. Bodies,
reserves, growth/damage, ancestry, parent-life IDs and coordinates are identical.
No biological tick, movement, mutation, sampling, feeding or healing occurs.
Destination bounds, conflicts and capacity must all validate before either result
is usable. A rejection leaves both inputs unchanged.
Source history retains every departed organism as nonresident, alive at its known
cut; departure is not death. Destination imports the selected organisms' exact
birth/revision facts and complete genome-parent closure. Returning an already
recorded dead organism is refused. Imported bud IDs retain their original region
namespace; only locally created buds consume the destination's own counter.
Nonresident archive facts confer no residency, stock or activity. Never use an
archive's known-alive count as an owned regional census or terminal world evidence.
The durable follow-on must freeze preparation under current authority, stage
read-only destination evidence, and commit both exact source/destination heads in
one fenced transaction. A failed second publication rolls back the first. Retries
retain the same prepared pair. Before commit, the frozen source owns the stock;
the destination ghost owns none. After commit, only the destination owns it. Abort
is durable and only before commit; timeout alone never releases another copy.
Retain source cuts, capsules, receipts and both histories.
The caller's stable workflow request UUID belongs to that durable I/O journal;
it is not a biological identity or a kernel PRNG decision. Source/destination head
comparison prevents a second application under a different request UUID.
This primitive changes ownership at an explicitly compatible cut and preserves
coordinates. It does not choose a physical route or let current clamped movement
cross an arena edge. Automatic linked-habitat movement, boundary contacts and
environmental-resource mappings need their own versioned contract and fidelity
tests; they cannot be inferred from passing escrow tests. No worker flag enables
those capabilities as part of this primitive.
## Alternatives, risks and qualification
Changing the old envelope silently breaks retained recovery. Marking departures
dead violates terminal death. Resetting opening inventories conceals transfers.
Generic mutable setters or unbacked destination births allow duplication. Retain
explicit paired candidates and boundary evidence instead.
Require complete per-member equality, per-channel source/destination balance,
archive retention/parent closure, foreign-identity admission, return trips without
resurrection, overlap/capacity/overflow rejection, encoded restore and continued
biology after import. Durable qualification additionally needs stale owners,
duplicate/conflicting delivery, partition/abort/restart and kills at each boundary.
This is an engineering transfer mechanism, not proof of coupled regional ecology,
world extinction, actual multi-day stability or useful compression.
+2
View File
@@ -161,3 +161,5 @@ design. No unadopted candidate is a link dependency of the proof.
- [ADR-0140: Exact population checkpoint and policy](0140-exact-population-checkpoint-and-policy.md)
- [ADR-0141: Cellular unattended demand and pacing](0141-cellular-unattended-demand-and-pacing.md)
- [ADR-0144: Exact wildlife transfer accounting](0144-exact-wildlife-transfer-accounting.md)