Skip to content

topmark.config.machine package index

topmark / config / machine

Machine-output support for config-related commands.

This package defines the machine-readable payload schemas and envelope builders used by TopMark config commands (config dump, config check, config init, config defaults). Where diagnostics are emitted, this package exposes the flattened compatibility view derived from staged config-validation logs.

Responsibilities:

  • Define payload schemas (in schemas.py) for:
  • flattened config (config)
  • layered provenance (config_provenance)
  • flattened compatibility config diagnostics (config_diagnostics)
  • config check summary (config_check)
  • Build JSON envelopes and NDJSON record streams (in envelopes.py)
  • Provide a stable contract for machine-readable output (json, ndjson)

Design notes:

  • This package belongs to the config domain, not the TOML domain. Although provenance payloads may include TOML fragments, the machine schemas represent command outputs rather than TOML documents.
  • The payload structure aligns with topmark.core.machine.schemas (MachineKey, MachineKind, MachineDomain).
  • Envelope builders are pure and side-effect free; serialization is handled by higher-level emitters.
  • Config-validation diagnostics are stored internally as staged validation logs (TOML-source, merged-config, runtime-applicability) and flattened only at the machine-readable output boundary.

Immediate children in this package

topmark.config.machine.envelopes
Envelope builders for config-related machine-readable output.
topmark.config.machine.payloads
Machine-output payload builders for TopMark config commands.
topmark.config.machine.schemas
Schema objects for config-related machine-readable output.
topmark.config.machine.serializers
Serialization helpers for config-related machine-readable output.