Changelog of @hackage/keiro-core 0.4.0.1

Changelog

All notable changes to keiro-core are recorded here. The format follows Keep a Changelog, and the package follows the Haskell Package Versioning Policy.

[Unreleased]

0.4.0.1 — 2026-07-28

Other Changes

  • Adds PVP upper bounds to every dependency that previously carried a lower bound only, so cabal check reports no packaging warnings. No API or behaviour change from 0.4.0.0, which was tagged but never published.

0.4.0.0 — 2026-07-28

Breaking Changes

  • StateCodec includes the control-state/fold shape discriminator used with the register-layout hash; stale snapshot seeds are invalidated when either executable state shape changes.
  • Validated event-stream construction rejects invalid event codec schemas, tags, and upcaster chains at assembly. mkEventStreamUnchecked remains the explicit emergency-forensics bypass.
  • Requires Keiki 0.4 and handles its typed projection terms and validation findings explicitly.

New Features

  • Adds the stable Keiro.Codec.Structural integration surface for generated structural codecs: total StructuralBinding values, deterministic labelled FixtureCases, both binding-law helpers, and one-way JSON delegation helpers.
  • Adds Keiro.Codec.Structural.Generic.genericStructuralBinding, an opt-in nominal adapter that accepts only exact constructor, selector, arity, order, and field-type correspondence and otherwise emits a compile-time direction to the scaffolded binding module.

0.3.0.0 — 2026-07-14

No user-facing changes. keiro-core is released at 0.3.0.0 to stay in lockstep with the rest of the Keiro package set.

0.2.0.0 — 2026-07-13

Breaking Changes

  • keiro-core now requires post-MP-16 Keiki 0.2 (keiki >=0.2 && <0.3) and Kiroku 0.3 (kiroku-store >=0.3 && <0.4). Stream validation runs Keiki's new head-recoverability, inversion-ambiguity, unguarded-input-read, and state-changing-silent-edge checks; any warning enabled by the selected ValidationOptions makes mkEventStream reject the stream at startup.
  • validateEventStreamWith and mkEventStreamWith now force-enable Keiki's checkHeadRecoverability and checkStateChangingEpsilon. Caller-supplied options may only strengthen validation at Keiro's durable boundary; use the explicitly unsafe mkEventStreamUnchecked only for tests and emergency forensics, never for production streams.
  • mkEventStream now rejects snapshot codecs that cannot encode their initial state and register file. Snapshot-enabled streams built from emptyRegFile must initialize every slot before validation; the labelled uninit: <slot> ErrorCall is reported as an EventStreamWarning instead of escaping at the first snapshot write.

New Features

  • New module Keiro.Schema, exporting keiroSchema :: Text ("keiro"). This is the single source of truth for the dedicated PostgreSQL schema that owns Keiro's framework tables: keiro-migrations creates them schema-qualified and the keiro runtime queries resolve against the same name.
  • Added mkEventStreamUnchecked, which wraps an EventStream with no Keiki or Keiro checks at all. It exists for tests and emergency forensics; a stream admitted through it can silently lose state changes and fail hydration.

Other Changes

  • Keiki 0.2 and Kiroku 0.3 now resolve from Hackage; their obsolete Git package overrides and the local Cabal overlay are no longer needed.
  • Added a deepseq dependency: validateEventStream forces the configured stateCodec over the initial state and registers, observing only ErrorCall so that any other exception stays programmer-visible.

0.1.0.0 — 2026-07-05

Initial Hackage release.

Breaking Changes

  • Finalized the pre-release stream naming, codec, and event-stream contracts, including safer stream category construction and validated event-stream boundaries.

New Features

  • Added shared Keiro.Codec, Keiro.Stream, Keiro.EventStream, Keiro.EventStream.Validate, Keiro.Integration.Event, Keiro.Snapshot.Policy, and Keiro.Prelude modules.
  • Added replay-safety validation helpers built on keiki's transducer validator.

Other Changes

  • Added Haddock coverage and migration documentation for validated event streams.