feat(cellular): region ticks of up to 4,096 lives for testing (schema 68)
Foundation / checks (checks) (push) Successful in 5s
Foundation / checks (client) (push) Successful in 5s
Foundation / checks (ecs) (push) Successful in 4s
Foundation / checks (deploy) (push) Successful in 5s
Foundation / checks (network) (push) Successful in 4s
Foundation / checks (postgres) (push) Successful in 5s
Foundation / checks (tsan) (push) Successful in 4s
Foundation / postgres-tools (push) Successful in 31s
Foundation / server-image (push) Successful in 4m29s
Foundation / image (push) Successful in 5m43s

ADR-0182 section 17. The plan's 2,000-organism cap became the rules-12
key region.organism_cap, which was parsed but never enforced; the real
bound was max_cellular_tick_lives = 256 (ADR-0106), which rules 13's
organism cap could not exceed. The bound is now 4,096, for testing limits
only; the DEV tuning file keeps 256.

- max_cellular_tick_lives (4,096) bounds the raw region path: step, owner
  state, batch trace (cellular_batch_bytes_for) and current checkpoint
  traces. max_cellular_frozen_lives (256) keeps cohort populations,
  population batches, migration traces and pre-v3 cellular traces, whose
  database checks are fixed.
- Tuning: reproduction.organism_cap and wildlife_cap accept up to 4,096.
- Schema 68: the trace checker under the current publishers
  (cellular_births_v45) accepts 4,096 intents, births and mutations per
  tick; spawn_wildlife takes up to 256 cells a command.
- Region view and portal: the lineage archive's fill (births of 65,536,
  genomes of 4,096), at which a region stops ticking.
- PostgreSQL suite: 256 wildlife spawned in one command, then a 289-life
  tick published and recovered exactly.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
dingo
2026-10-28 17:30:22 -04:00
co-authored by Claude Opus 5.5
parent 8005e7c4ae
commit 3c753970c8
29 changed files with 301 additions and 49 deletions
+12 -3
View File
@@ -143,6 +143,7 @@ SELECT EXISTS (SELECT 1 FROM pg_catalog.pg_namespace WHERE nspname='evolution')
SELECT :'history_v64' || ',65:' || :'migration_sha_65' AS history_v65 \gset
SELECT :'history_v65' || ',66:' || :'migration_sha_66' AS history_v66 \gset
SELECT :'history_v66' || ',67:' || :'migration_sha_67' AS history_v67 \gset
SELECT :'history_v67' || ',68:' || :'migration_sha_68' AS history_v68 \gset
SELECT :'history' = :'history_v22' AS at_v22,
:'history' = :'history_v23' AS at_v23,
:'history' = :'history_v24' AS at_v24,
@@ -188,8 +189,10 @@ SELECT EXISTS (SELECT 1 FROM pg_catalog.pg_namespace WHERE nspname='evolution')
:'history' = :'history_v64' AS at_v64,
:'history' = :'history_v65' AS at_v65,
:'history' = :'history_v66' AS at_v66,
:'history' = :'history_v67' AS at_v67 \gset
\if :at_v67
:'history' = :'history_v67' AS at_v67,
:'history' = :'history_v68' AS at_v68 \gset
\if :at_v68
\elif :at_v67
\elif :at_v66
\elif :at_v65
\elif :at_v64
@@ -617,7 +620,8 @@ SELECT coalesce(max(version), 0) = 24 AS at_v24,
coalesce(max(version), 0) = 64 AS at_v64,
coalesce(max(version), 0) = 65 AS at_v65,
coalesce(max(version), 0) = 66 AS at_v66,
coalesce(max(version), 0) = 67 AS at_v67
coalesce(max(version), 0) = 67 AS at_v67,
coalesce(max(version), 0) = 68 AS at_v68
FROM evolution.schema_migrations \gset
\if :at_v24
\ir 0025_cellular_v2_bundle.sql
@@ -853,6 +857,7 @@ SELECT coalesce(max(version), 0) = 24 AS at_v24,
\elif :at_v65
\elif :at_v66
\elif :at_v67
\elif :at_v68
\else
\echo 'Unknown or changed migration history after v43'
DO $$ BEGIN RAISE EXCEPTION 'unknown or changed migration history'; END $$;
@@ -953,6 +958,10 @@ SELECT coalesce(max(version), 0) = 66 AS needs_v67 FROM evolution.schema_migrati
\if :needs_v67
\ir 0067_admin_take_and_cull.sql
\endif
SELECT coalesce(max(version), 0) = 67 AS needs_v68 FROM evolution.schema_migrations \gset
\if :needs_v68
\ir 0068_larger_region_ticks.sql
\endif
-- Effective-privilege audit on every run, including no-ops (ADR-0060). Attributes
-- alone are insufficient: predefined roles such as pg_write_all_data, PUBLIC
-- grants or SET-able memberships would bypass the fenced functions. Checks the