Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions REFERENCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -281,6 +281,7 @@ explicitly unspecified. Imaging Delaunay/Rectangular also expose empty Numba/JAX
filters when there are no measurements; these links claim neither runtime nor
implementation availability. Instrument selection updates the URL within the
opened tab and supports browser history. Existing setup links still resolve.
Routine capture/integrity metadata is in Evidence details; actual stale, failed,
cached and local-preview warnings remain visible. Campaign tables display only
Routine capture/integrity metadata is available in the machine-readable receipts
and snapshots, not an Evidence details disclosure. Actual stale, failed, cached
and local-preview warnings remain visible. JAX choices carry an explicit (JAX) label. Campaign tables display only
name, recent progress and next steps; the complete ledger remains authoritative.
46 changes: 23 additions & 23 deletions dashboard.html

Large diffs are not rendered by default.

10 changes: 2 additions & 8 deletions insight/board.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,20 +142,14 @@ def _detail(s, now=None):
warnings = []
if s.cached or s.errors:
warnings.append(
"Latest refresh failed; see Evidence details"
+ (". Showing cached evidence." if s.cached else ".")
"Latest refresh failed" + (". Showing cached evidence." if s.cached else ".")
)
if s.source == "local":
warnings.append("Local preview, not a published capture.")
if freshness(s, now).startswith("stale"):
warnings.append("Evidence is past its declared freshness deadline.")
alerts = "".join('<p class="warn">' + e(message) + "</p>" for message in warnings)
return (
marker(s)
+ alerts
+ nav
+ setup_browser.disclosure("Evidence details", "".join(parts[2:]))
)
return marker(s) + alerts + nav
if not d:
return "".join(parts)
parts += [
Expand Down
9 changes: 3 additions & 6 deletions insight/setup_browser.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ def model_label(model, impl):
if impl == "numba"
else " (implementation unspecified)"
if impl == "unknown"
else " (JAX)"
if impl == "jax"
else ""
)

Expand Down Expand Up @@ -113,7 +115,7 @@ def record(snapshot, row):


def page(snapshot, setup, rows, now=None, impl=None, instruments=()):
from insight.board import freshness, integrity, qualification
from insight.board import freshness

doc = snapshot.doc
sid = setup["id"]
Expand All @@ -139,10 +141,6 @@ def page(snapshot, setup, rows, now=None, impl=None, instruments=()):
out.append(
f'<div class="selectors"><label>Instrument<select data-instrument>{options}</select></label></div>'
)
evidence = (
f"<p>Integrity: {e(integrity(snapshot))} · Freshness: {e(freshness(snapshot, now))} · Scientific qualification: {e(qualification(snapshot))}</p>"
f"<p>Captured source branch: {e(snapshot.source_branch)}. Revision: {e(snapshot.commit)}. Capture time: {e(snapshot.fetched_at)}. Latest attempt: {e(snapshot.attempt_at)}.</p>"
)
if freshness(snapshot, now).startswith("stale"):
out.append('<p class="warn">This evidence is past its declared freshness deadline.</p>')
if snapshot.errors:
Expand Down Expand Up @@ -251,7 +249,6 @@ def page(snapshot, setup, rows, now=None, impl=None, instruments=()):
+ "</ul>",
)
)
out.append(disclosure("Evidence details", evidence))
out.append("</details>")
return "".join(out)

Expand Down
6 changes: 3 additions & 3 deletions tests/browser_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def main():
detail.wait_for_load_state()
assert "view=setup" in detail.url
assert not detail.locator("#inference-home").is_visible()
assert detail.locator(".setup-page:not([hidden]) h1").inner_text() == "Delaunay"
assert detail.locator(".setup-page:not([hidden]) h1").inner_text() == "Delaunay (JAX)"
assert (
detail.locator(".setup-page:not([hidden])")
.get_by_text("No accepted baseline selected", exact=True)
Expand All @@ -76,7 +76,7 @@ def main():
active.locator("[data-instrument]").select_option(label="EUCLID")
assert "euclid" in detail.url and "implementation=jax" in detail.url
assert (
"No recorded Delaunay results"
"No recorded Delaunay (JAX) results"
in detail.locator(".setup-page:not([hidden])").inner_text()
)
detail.go_back()
Expand All @@ -100,7 +100,7 @@ def main():
detail.set_viewport_size({"width": 390, "height": 844})
assert detail.evaluate("document.documentElement.scrollWidth <= innerWidth")
detail.goto(path.as_uri() + "?view=setup&instance=lens&setup=imaging%2Fdelaunay%2Fhst")
assert detail.locator(".setup-page:not([hidden]) h1").inner_text() == "Delaunay"
assert detail.locator(".setup-page:not([hidden]) h1").inner_text() == "Delaunay (JAX)"
detail.goto(path.as_uri() + "?view=setup&instance=lens&setup=missing")
assert detail.locator("#inference-home").is_visible()
assert "unavailable" in detail.locator("#setup-route-status").inner_text()
Expand Down
5 changes: 3 additions & 2 deletions tests/test_setup_browser.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,9 @@ def test_direct_page_retains_failed_refresh_and_local_preview_qualifications(
snapshot.errors = ["latest refresh failed <network>"]
snapshot.doc["valid_until"] = "2026-01-01T00:00:00Z"
_, pages = setup_browser.render(snapshot, now="2026-10-08T00:00:00Z")
assert "stale · deadline" in pages
assert "Freshness:" in pages and "Integrity:" in pages
assert "past its declared freshness deadline" in pages
assert "Evidence details" not in pages
assert "Integrity:" not in pages
assert "latest refresh failed &lt;network&gt;" in pages
assert "original capture and evidence times retained" in pages
snapshot.source = "local"
Expand Down
Loading