Preserve composite ConfigKit provenance

This commit is contained in:
2026-10-04 13:34:27 +00:00
parent 428f435734
commit f1672f6f95
13 changed files with 200 additions and 145 deletions

View File

@@ -74,7 +74,10 @@ commands do not marshal runtime objects directly.
`EffectivePipelineSources` and `EffectiveCampaignSources` provide the separate
safe provenance projection for `config sources`. Pipeline ownership begins with
the complete logical field paths projected from the schema and classifies
each contributor as root, import, overlay, or centralized default. The
each contributor as root, import, overlay, or centralized default. It reads
ConfigKit's effective origins and inheritance locations when building each
projection, so inherited values retain their contributors and controlling
directives without a second cached leaf-ownership table. The
projection replaces generated concrete member paths with paired family and
canonical-party records, and does the same for generated publish rules.
Campaign records identify campaign-owned fields and party inputs; canonical
@@ -84,8 +87,9 @@ records with selection metadata and never reparses configuration files.
`EffectiveArtifactCatalog` projects the same finalized concrete artifact map for
`config artifacts`. It derives source identity from each map key, carries sorted
effective dependencies, aggregates ConfigKit definition contributors, and adds
family/character/party provenance for generated members. It does not inspect
files named after artifacts or infer another runtime graph.
family/character/party provenance for generated members. Family source evidence
can name multiple contributing files. It does not inspect files named after
artifacts or infer another runtime graph.
`config diff` uses a thin paired loader that performs two independent ConfigKit
loads. When campaign
@@ -152,10 +156,8 @@ rediscovering additional conflicts.
The loaded pipeline retains private runtime metadata for the absolute root
path, ordered imports, selected overlay name, source, and path, original
ConfigKit metadata and source snapshots, effective digest,
and leaf ownership. Base
leaves retain their root/import owners, replaced leaves belong to the selected
overlay, and centrally supplied values use the synthetic `default` owner. This
ConfigKit metadata and source snapshots, and effective digest. Leaf source
records are projected from that retained native metadata when requested. This
metadata does not participate in YAML decoding or alter the public
configuration model.
@@ -179,8 +181,8 @@ for later runtime expansion.
## Test Surfaces
`pipeline_configkit_test.go` exercises real imports and fixed-path overlays,
base selection, unselected-overlay isolation, source attribution, and Narratio's
unique artifact/family base-declaration rule. Existing focused configuration
base selection, unselected-overlay isolation, source attribution, cross-file
inheritance, and effective composition. Existing focused configuration
tests protect defaults, explicit-value semantics, strict decoding, validation,
metadata, and root-relative path behavior. Application configuration-loader tests protect the
single-read boundary by changing the pipeline file after its initial load and