Skip to main content

Python source-mode loader for MDA v1.0 configuration artifacts

Project description

snoai-mda-config

Python source-mode loader for MDA v1.0 configuration artifacts.

This package mirrors the TypeScript @snoai/mda-config and Rust snoai-mda-config loader contract. The v1.0 surface covers frontmatter extraction, MDA source-schema validation, integrity verification, requires.network enforcement, Sigstore verification hooks, and consumer pydantic validation.

Python does not perform real Rekor transport or Sigstore cryptography by itself. When verify_signatures=True, callers must provide a trust policy, Rekor client, and Sigstore verifier hook. Missing verifier pieces fail closed.

from pathlib import Path
from pydantic import BaseModel
from snoai_mda_config import load_mda_source


class Preset(BaseModel, extra="forbid"):
    name: str
    description: str
    metadata: dict | None = None
    integrity: dict | None = None
    signatures: list[dict] | None = None


config = load_mda_source(
    Path("preset.mda"),
    schema=Preset,
    verify_integrity=True,
)

For signed presets, also pass verify_signatures=True, trust_policy=..., rekor_client=..., and sigstore_verifier=.... For capability enforcement, pass enforce_requires=True with allowed_networks=[...].

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

snoai_mda_config-1.1.0.tar.gz (14.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

snoai_mda_config-1.1.0-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file snoai_mda_config-1.1.0.tar.gz.

File metadata

  • Download URL: snoai_mda_config-1.1.0.tar.gz
  • Upload date:
  • Size: 14.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for snoai_mda_config-1.1.0.tar.gz
Algorithm Hash digest
SHA256 a19c988ca0520010cedd8860b1966f96bb852eedfcd71a2b28db39b6ac952071
MD5 9640f3105c6f3cc29b8b36613ac92600
BLAKE2b-256 490917728f2f524833900633463af2840dd033fa7301e0f8ab17fa1b4f92c57d

See more details on using hashes here.

Provenance

The following attestation bundles were made for snoai_mda_config-1.1.0.tar.gz:

Publisher: publish-pypi.yml on sno-ai/mda-config

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file snoai_mda_config-1.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for snoai_mda_config-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 143c8fbc101ccb3b3dde53310feab081baeb94675b7dc831ec7adcdc0363937f
MD5 85933c5f69df13fde560eef25d801a09
BLAKE2b-256 4171fec60b043136ab9a37d89b5dc1ccfe1a5823b69290d75016abf143febfc3

See more details on using hashes here.

Provenance

The following attestation bundles were made for snoai_mda_config-1.1.0-py3-none-any.whl:

Publisher: publish-pypi.yml on sno-ai/mda-config

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page