feat: migrate View 0.3.0 to marqdo 3.0.0-rc.4 contracts
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/push/woodpecker Pipeline was successful
Replace the retired rc.2 Analysis v2/Trace v2/Execution Events v1 stack with the
single current contract family:
- Analysis v3 (ADR-0069 public boundary): one check --emit artifact carries the
exact source, Markdown AST, heading scopes (heading_span + complete span),
anchors, state-bearing references, calls, resources and diagnostics; the old
revision-3 shape is rejected with a rebuild hint.
- Observation v1: one run/call --output jsonl stream (+ atomic
--observation-file snapshot) decoded by one decoder and projected into the
reader/SSE/export layers; stale/malformed/truncated/incomplete never render
as success.
- CLI Tool revision 1: requires {api_revision:1, analysis:3, observation:1},
product range >=3.0.0-rc.3,<4.0.0, only MARQDO_BIN and
MARQDO_API_REVISION are consumed.
- Remove compatibility branches, retired flags/env vars and duplicate decoders;
re-record Analysis v3 and Observation v1 fixtures; rewrite contract,
integration and security tests (173 passing locally).
- Add check-no-legacy/check-docs/check-observation gates, rc.4 pins in the
CI pipelines, 0.3.0 Tool bundle and evidence manifest support.
See issues #4, #5 and #6; acceptance baseline is CLI source
452e9a32bd9e40dba427d4180691c58bab74449e, archive
9c3f166b5e5b8840d39d10019074e4e1c42432fc23e26c69670e64fdcf4e15d8.
This commit is contained in:
1 parent
7b34199c96
commit
340ecb035f
108 files changed
+13928
-6461
No files matched your search
@@ -181,9 +181,66 @@ fn tool_manifest_matches_package_and_protocols() {
|
||||
env!("CARGO_PKG_VERSION"),
|
||||
"tool.json version must match Cargo package version"
|
||||
);
|
||||
assert_eq!(tool["compatibility"]["marqdo"], ">=3.0.0-beta.1,<4.0.0");
|
||||
assert_eq!(tool["compatibility"]["analysis"], serde_json::json!([2, 3]));
|
||||
assert_eq!(tool["compatibility"]["trace"], serde_json::json!([2]));
|
||||
assert_eq!(
|
||||
tool["requires"],
|
||||
serde_json::json!({"api_revision": 1, "analysis": 3, "observation": 1}),
|
||||
"the manifest must declare exact current revisions"
|
||||
);
|
||||
assert!(
|
||||
tool.get("compatibility").is_none(),
|
||||
"the retired compatibility negotiation block must not return"
|
||||
);
|
||||
let keys: Vec<&str> = tool
|
||||
.as_object()
|
||||
.unwrap()
|
||||
.keys()
|
||||
.map(String::as_str)
|
||||
.collect();
|
||||
assert_eq!(
|
||||
keys,
|
||||
vec![
|
||||
"command",
|
||||
"entrypoint",
|
||||
"name",
|
||||
"requires",
|
||||
"schema",
|
||||
"schema_version",
|
||||
"version"
|
||||
],
|
||||
"tool.json must not carry retired fields"
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn source_has_no_legacy_protocol_or_runtime_probing() {
|
||||
let root = manifest_dir();
|
||||
let mut sources = Vec::new();
|
||||
collect_files(&root.join("src"), "rs", &mut sources);
|
||||
let banned = [
|
||||
"analysis_v2",
|
||||
"trace_v2",
|
||||
"execution_events_v1",
|
||||
"MARQDO_TOOL_PROTOCOL",
|
||||
"MARQDO_PROTOCOL_ANALYSIS",
|
||||
"MARQDO_PROTOCOL_TRACE",
|
||||
"--trace-file",
|
||||
"--event-stream",
|
||||
"compatibility",
|
||||
];
|
||||
for path in sources {
|
||||
// Unit-test modules may assert that a retired flag is absent; the gate
|
||||
// scans production source only.
|
||||
let text = read(&path);
|
||||
let production = text.split("#[cfg(test)]").next().unwrap_or("").to_string();
|
||||
for needle in banned {
|
||||
assert!(
|
||||
!production.contains(needle),
|
||||
"{} still references retired contract marker {:?}",
|
||||
path.display(),
|
||||
needle
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
||||
Reference in new issue
Block a user