Skip to main content

Module verification

Module verification 

Source
Expand description

Verification profile store and stale-diagnostic contract primitives.

Provides the verification_profiles_get, verification_profiles_set, verification_profile_resolve, verification_profile_matches, verification_profile_record_run, and verification_diagnostic_classify builtins.

A profile record set is a versioned (schemaVersion: 1) list of check rows keyed by scope selectors (repo -> dir glob -> language -> task kind), resolved most-specific-wins. Rows are opaque JSON objects: the store reads and updates only the fields it owns (id, scope, timings, lastRun) and round-trips every other field untouched, so newer writers can extend rows without breaking older readers. Languages and toolchains are data in the rows — nothing in this module names a language, toolchain, or build system.

Persistence rides the hierarchical project metadata store (metadata.rs) under the verification-profiles namespace, giving the record set the same durability, sharding, and host-fallback behavior as the other cross-run learning namespaces.

The stale-diagnostic contract half is pure: a diagnostic envelope {rung, rowId, at, snapshot} is classified against the current file->hash map as bound_fresh (may feed no-progress detectors, escalation streaks, verifier signatures, and completion gates), bound_stale (an edit invalidated the snapshot; suppressed to advisory and marked stale), or unbound (advisory-only; must never feed gates). Loop consumers gate on the returned feedsGates bit; wiring the detectors onto that bit lives with them, not here.