feat(compiler): end-to-end compile and check orchestration
- resolve scope, discover exact snapshot, project plain Markdown, run real Analysis for .mq.md entries, cross-check module source bytes, merge contexts and reject uncovered/invalid Marqdo documents - collect referenced local assets and known-missing paths before linking so a missing file is distinguished from an unindexed/excluded one - incremental plan by content-digest change set: unchanged documents reuse digest-guarded facts; any .mq.md/manifest/lock/core-identity change triggers the conservative full re-analysis; plain-only edits never invoke Analysis - no-op compiles preserve the stored snapshot and generation; rebuilds increment the generation and atomically replace the artifact - recheck every source digest immediately before publishing, never mixing snapshots, and refuse to publish graphs with blocking diagnostics - check validates sources, references, Analysis coverage, database structure and currentness, writes nothing and exits 1 for definite broken links - add end-to-end tests for plain-only compile without a core binary, mixed real-Analysis compile, incremental/rebuild/no-op, stale database and broken links
This commit is contained in:
1 parent
cca8fbdab1
commit
66f3e168c4
5 files changed
+1106
-14
No files matched your search
+23
-1
@@ -1,3 +1,25 @@
|
||||
//! OKF v0.3 document-layer recognition and `check --okf` validation.
|
||||
//!
|
||||
//! Implemented in the OKF milestone.
|
||||
//! OKF is an optional Markdown organisation convention, not a project type and
|
||||
//! not an additional knowledge format. Recognition only reads front-matter
|
||||
//! metadata and fixed file roles; it never executes an executor/attester and
|
||||
//! never changes program semantics.
|
||||
//!
|
||||
//! Implemented by the OKF milestone. Until then `--okf` reports an explicit
|
||||
//! unverified diagnostic instead of pretending to validate.
|
||||
|
||||
use crate::diagnostic::{code, Diagnostic, DiagnosticSet};
|
||||
use crate::document::{DocumentFacts, SourceSnapshot};
|
||||
|
||||
/// Validate the supported OKF surface for an explicitly requested bundle.
|
||||
pub fn validate_okf(_snapshot: &SourceSnapshot, _facts: &[DocumentFacts]) -> DiagnosticSet {
|
||||
let mut diagnostics = DiagnosticSet::new();
|
||||
diagnostics.push(
|
||||
Diagnostic::warning(
|
||||
code::OKF_UNVERIFIED,
|
||||
"OKF v0.3 validation is not implemented in this build; no OKF claim is made",
|
||||
)
|
||||
.with_hint("see docs/STATUS.md for the current capability matrix"),
|
||||
);
|
||||
diagnostics
|
||||
}
|
||||
Reference in new issue
Block a user