Record repository UI status in the scanner and tolerate older jsonschema.

Adds the repo-ui-metadata extractor (ui_status yes/candidate/not_detected
plus ui_evidence), falls back to the legacy validator when jsonschema does
not accept a referencing registry, and covers unknown edge endpoints in the
graph explorer.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

Assistant: claude-code
Assistant-Model: opus
Assistant-Process: 7458@bnt-lap001
Assistant-Session: 62534cdf-8348-48a7-9c0d-46e0f74c8eae
This commit is contained in:
codex 2026-09-22 08:06:04 +02:00
parent c65b9eddfe
commit 564dc59c4f
5 changed files with 138 additions and 4 deletions

View file

@ -159,6 +159,25 @@ def test_graph_explorer_collapses_discovered_repository_nodes() -> None:
assert declares_package["data"]["displayOnly"] is False
def test_graph_explorer_materializes_unknown_edge_endpoints() -> None:
graph = {
"apiVersion": "railiance.fabric/v1alpha1",
"kind": "FabricGraphExport",
"nodes": [{"id": "repo:reef-railiance", "kind": "Repository", "name": "reef-railiance", "repo": "reef-railiance"}],
"edges": [{"from": "repo:reef-railiance", "to": "repo:rail-knative", "type": "hosts_rail"}],
}
payload = fabric_graph_explorer_payload(graph, [{"slug": "reef-railiance", "name": "reef-railiance"}], {"reef-railiance"})
nodes = [element for element in payload["elements"] if "source" not in element["data"]]
edges = [element for element in payload["elements"] if "source" in element["data"]]
unknown = next(node for node in nodes if node["data"]["id"] == "repo:rail-knative")
edge = next(edge for edge in edges if edge["data"]["target"] == "repo:rail-knative")
assert unknown["data"]["kind"] == "Unknown"
assert unknown["data"]["unresolved"] is True
assert edge["data"]["source"] == "repo:reef-railiance"
def test_graph_explorer_surfaces_repository_source_references() -> None:
graph = {
"apiVersion": "railiance.fabric/v1alpha1",