epiphany/crates/epiphany-ops/src
Levi Neuwirth d93baac3ba Agent K M2d review follow-up: harden the Group-4 score-settings ops
Address the five-finding review of M2d (1e4ab24) plus the two-finding
follow-up review; all fixes are code/test/doc only, no spec change needed
(the catalog/core-spec already classify metadata as advisory LWW).

- SetMetadata is now a true advisory LWW: it silently last-writer-wins in
  canonical order and records no conflict, matching operation_catalog
  §set-user-system-break. Dropped the StructuralFieldCollision, the
  `last_metadata` working slot, and the `env` parameter; rewrote the
  conflict test as `concurrent_differing_set_metadata_is_advisory_lww`
  (no conflict, state stays clean, permutation-independent resolution).
- SetMetricGrid / SetUserPageBreak / SetUserSystemBreak share a new
  `layout_region_slot` precondition backed by a `staff_based_regions`
  index: the target must be live and staff-based (FreeGraphic regions have
  neither a metric-grid nor a break slot). The index is read from base-free
  state, so reduce() and reduce_onto() reach the same verdict for missing,
  tombstoned, and FreeGraphic regions.
- SetMetricGrid now rejects a grid whose meter_sequence names an undeclared
  time signature, rather than installing an invariant-violating grid.
- User breaks materialize under the canonical LWW key: `apply_break_lww`
  drops any existing anchor resolving to the same position before adding,
  so the graph break list stays in lockstep with the resolved-position
  ledger map (shared `resolved_anchor_position`). Applied to page and
  system breaks alike.
- Coverage: SetMetadata/SetMetricGrid/CreateVoice/DeleteVoice added to the
  tag-distinctness test; layout_stub `gen_operation_kind_tag` extended to
  every normative tag; the MaterializedState decode test populates
  page_breaks; four direct regression tests pin each fixed bug; the stale
  SetMetadata/score_metadata doc comments now say advisory LWW.

Gates: build/fmt/clippy -D warnings clean; cargo test --workspace green
(533); conformance_suite scale 1 passes. Stages only core/ops/testkit; the
unrelated Agent-I working tree is left untouched.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-25 21:45:51 -04:00
..
anomaly.rs Phase 2 (Agent K) M1: value-typed operation payloads + Operation Catalog scaffold 2026-06-24 11:52:02 -04:00
causal.rs Pass 11: ratify provisional byte choices into normative spec text 2026-06-21 22:30:06 -04:00
conflict.rs Pass 11: consolidated byte-layout appendix + pin ObjectKind/ResolutionAction discriminants 2026-06-22 13:16:20 -04:00
decode.rs Agent K M2d (Group 4): score-settings operations 2026-06-25 19:26:31 -04:00
effect.rs Agent K M2c (Group 3): structural container CRUD operations 2026-06-25 18:10:15 -04:00
encode.rs A B C D F 2026-06-19 12:42:31 -04:00
envelope.rs Phase 2 (Agent K) M1: value-typed operation payloads + Operation Catalog scaffold 2026-06-24 11:52:02 -04:00
fuzz.rs Agent K M2d (Group 4): score-settings operations 2026-06-25 19:26:31 -04:00
lib.rs Agent K M2d (Group 4): score-settings operations 2026-06-25 19:26:31 -04:00
migrate.rs Agent K M2d (Group 4): score-settings operations 2026-06-25 19:26:31 -04:00
opset.rs Phase 2 (Agent K) M1: value-typed operation payloads + Operation Catalog scaffold 2026-06-24 11:52:02 -04:00
payload.rs Agent K M2d review follow-up: harden the Group-4 score-settings ops 2026-06-25 21:45:51 -04:00
reduce.rs Agent K M2d review follow-up: harden the Group-4 score-settings ops 2026-06-25 21:45:51 -04:00
slot.rs A B C D F 2026-06-19 12:42:31 -04:00
stamp.rs A B C D F 2026-06-19 12:42:31 -04:00
support.rs Pass 11 follow-up: golden-lock the ratified discriminant tables; fix three spec-text inaccuracies 2026-06-22 09:22:55 -04:00
undo.rs A B C D F 2026-06-19 12:42:31 -04:00
v0.rs Agent K M2d (Group 4): score-settings operations 2026-06-25 19:26:31 -04:00
valuegen.rs Agent K M2d review follow-up: harden the Group-4 score-settings ops 2026-06-25 21:45:51 -04:00