feat(lifecycle): rules 13 owner on format 11 with the revamp tuning file
Foundation / checks (client) (push) Successful in 4s
Foundation / checks (checks) (push) Successful in 4s
Foundation / checks (ecs) (push) Successful in 4s
Foundation / checks (network) (push) Successful in 4s
Foundation / checks (postgres) (push) Successful in 3s
Foundation / checks (tsan) (push) Successful in 5s
Foundation / checks (deploy) (push) Successful in 4m30s
Foundation / postgres-tools (push) Successful in 22s
Foundation / server-image (push) Successful in 4m12s
Foundation / image (push) Successful in 4m40s
Foundation / checks (client) (push) Successful in 4s
Foundation / checks (checks) (push) Successful in 4s
Foundation / checks (ecs) (push) Successful in 4s
Foundation / checks (network) (push) Successful in 4s
Foundation / checks (postgres) (push) Successful in 3s
Foundation / checks (tsan) (push) Successful in 5s
Foundation / checks (deploy) (push) Successful in 4m30s
Foundation / postgres-tools (push) Successful in 22s
Foundation / server-image (push) Successful in 4m12s
Foundation / image (push) Successful in 4m40s
Phase 1 of the cellular revamp build plan (ADR-0179). The cellular owner gains rules 13 on owner format 11: an explicit no-tick format-10/rules-12 upgrade declares the region's revamp rules (so far the body's essential upkeep share), existing lives keep their genomes, and founders born afterwards are founder 6 (genome schema 7, development 7). Format 11 is format 10 plus the revamp rules block; it stays undeployed while later phases extend it. The tick, perception and wildlife controller derive budgets with the declared body tuning, which earlier development versions ignore. Revamp tunables live in their own Git file, deploy/kubernetes/region/dev/tuning/cellular-revamp.tuning, parsed by parse_cellular_revamp_tuning with the same format and refusals as the rules-12 file, so images from before rules 13 never meet keys they do not know. Both parsers now share read_tuning_lines; the rules-12 file's behaviour is unchanged. The revamp file is not yet mounted into the region (build plan, phase 6). Tests cover the upgrade and its refusals, mixed founder 5 and founder 6 lives ticking with closure, exact restore and continuation, trace replay, and the new tuning file including the checked-in DEV copy. Refreshes the DEV session window. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
#pragma once
|
||||
|
||||
#include "evo/biology/cellular_tuning.hpp"
|
||||
|
||||
#include <compare>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <expected>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
|
||||
// Git-managed trial values for the cellular revamp (rules 13, ADR-0179), in their own file
|
||||
// beside the rules-12 tuning file so older images never meet keys they do not know. Same
|
||||
// format and rules: plain `key = value` integer lines, every key required exactly once and
|
||||
// range-checked. Later build phases add feeding, mutation and reproduction keys.
|
||||
namespace evo::biology {
|
||||
inline constexpr std::int64_t cellular_revamp_tuning_version = 1;
|
||||
inline constexpr std::size_t max_cellular_revamp_tuning_bytes = std::size_t{256} * 1'024;
|
||||
|
||||
struct CellularRevampTuning {
|
||||
std::int64_t version{};
|
||||
// Body: the share of upkeep no upkeep-efficiency trait reduces.
|
||||
std::int64_t body_essential_upkeep_per_mille{};
|
||||
auto operator<=>(const CellularRevampTuning&) const = default;
|
||||
};
|
||||
|
||||
[[nodiscard]] std::expected<CellularRevampTuning, CellularTuningError>
|
||||
parse_cellular_revamp_tuning(std::string_view text);
|
||||
// Canonical text: every key once, in schema order.
|
||||
[[nodiscard]] std::string encode_cellular_revamp_tuning(const CellularRevampTuning& tuning);
|
||||
} // namespace evo::biology
|
||||
Reference in New Issue
Block a user