Files
configkit/docs/releases/v1.5.0.md

4.1 KiB

ConfigKit v1.5.0

Applications can now inspect rejected configuration through the same reporting interface used for successful loads. Imports also support absolute paths and shared files outside the main configuration directory, with explicit containment available when needed.

Inspect rejected configuration

LoadError.InspectSubtree(path) returns an Inspection view when a failed load retained a coherent snapshot. Consumers can render values, explain their origins, inspect history and resource contexts, and compare views across successful and failed loads using the existing redaction rules. Inspection does not reopen sources or rerun callbacks.

The new Inspection.Stage() identifies the processing completed for a snapshot, from main-tier composition through validation. Failed phases do not contribute partial changes: a failing resolver exposes its entry candidate, and a failing validator exposes the candidate presented to it. Early failures and existing history limits can leave no view available; callers must check availability.

Loading still returns a nil result and an error on failure. A reporting view does not turn rejected configuration into a successful execution result, and the original diagnostics remain authoritative. Checkpoint contract · Inspection API · Consumer example

Absolute and parent-relative imports

Enabled host imports now accept absolute paths and paths outside the main configuration directory. Relative selectors resolve from the declaring file's canonical directory, including within imported external files. The same rules apply to path, dir, and glob selectors. Host byte, reader, and mapping inputs can supply FilesystemContext.BaseDir without a Root.

Host imports are unbounded by default. Applications relying on the former default containment should explicitly set FilesystemContext.Root to the main file's canonical directory. An explicit root bounds canonical targets, including symlinks and transitive imports. Existing explicit roots retain containment.

Within a supplied fs.FS, a leading / starts at that namespace's root. Imports remain in the selected namespace; Go source and context arguments retain their slash-relative path syntax.

External host sources receive resource contexts rooted at their own canonical directories. Existing contained-source resource coordinates remain supported. Import widening leaves selected-overlay lookup and configured secrets-bootstrap boundaries unchanged. Prepared main sources retain their captured import policy; a later compatible explicit root can narrow an unbounded capture. Import contract · Resource contexts · Consumer example

Fixes and maintenance

  • Resolve parent components inside symlink targets in filesystem order for host imports and inspected native glob prefixes, avoiding selection of the wrong directory.
  • Preserve the completed main-tier snapshot when a later load phase fails, and record consumption of nested inheritance selectors in inspection history.
  • Reduce repeated source-history searches and literal glob-prefix traversal.
  • Adopt ReleaseKit v0.11.0 and update local delivery credentials and optional readiness diagnostics in the release procedure.

Compatibility

The new APIs and import forms are additive. Existing valid configurations remain supported; applications requiring the earlier implicit import boundary should set an explicit root as described above. Composition, precedence, source-version checks, and ordinary loading's environment behavior remain unchanged. The Go consumer minimum remains 1.27.0.

COPYRIGHT | LICENSE | ATTRIBUTION