Skip to content

gittuf.toml and hello.toml use [framework] section header but loader requires [metadata] #361

Description

@mlieberman85

Background

The framework config loader (packages/darnit/src/darnit/config/merger.py -> FrameworkConfig pydantic model) requires a top-level [metadata] TOML section. openssf-baseline.toml, reproducibility.toml, and other TOMLs use [metadata] correctly.

Two TOMLs use [framework] instead and fail schema validation:

  • packages/darnit-gittuf/src/darnit_gittuf/gittuf.toml:1 -- [framework]
  • packages/darnit-hello/src/darnit_hello/hello.toml:16 -- [framework]

Symptom

Running uv run darnit list reports for each:

INFO:   * gittuf (error loading: 1 validation error for FrameworkConfig
metadata
  Field required [type=missing, input_value={'framework': {'name': 'g...

Discovery context

Surfaced by feature 021 (config path fix, PR TBD). Before feature 021, wheel installs could not locate these TOMLs at all, so validation never ran and the mismatch was silent. After feature 021 the TOMLs load, and the loader correctly rejects the schema mismatch.

Fix

Rename the top-level section header in both TOMLs from [framework] to [metadata]. Verify the rest of the schema still matches FrameworkConfig.

Scope

Preexisting; not caused by feature 021. Small change (two lines). Should NOT be bundled into the 021 PR; file separately to keep 021 focused on the packaging fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions