Explorer: a chain block whose plan the observer has not read says so (the scene's wording rule of 7 October 2026)

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
igneum-labs 2026-10-08 10:34:09 +00:00
parent 960f081ad2
commit efb5b330dd
3 changed files with 3 additions and 3 deletions

View file

@ -357,7 +357,7 @@ async function load() {
const chips = [b.chain ? (b.chain_now === false ? '<span class="chip" title="the observer saw it as the chain block of its number; a tip reorg gave the number to another block">chain block, replaced</span>' : '<span class="chip hot">chain block</span>') : `<span class="chip">${esc(b.color)}</span>`, `<span class="chip" title="the hash program family this block was mined under">class ${esc(b.class ? b.class.class : 'v4')}</span>`];
if (j.checkpoint) chips.push(`<span class="chip ${j.checkpoint.state === 'locked' ? 'ok' : ''}">checkpoint ${j.checkpoint.index}, ${esc(j.checkpoint.state)}</span>`);
chips.push(b.lock && b.lock.final ? `<span class="chip ok" title="${esc(b.lock.reason)}">final under lock ${int(b.lock.index)}</span>` : `<span class="chip" title="${esc(b.lock ? b.lock.reason : '')}">not under a lock yet</span>`);
if (b.chain) chips.push(sum.total ? `<span class="chip ${sum.paid === sum.total ? 'ok' : ''}">${sum.paid} of ${sum.total} shards paid</span>` : '<span class="chip">no shard plan yet</span>');
if (b.chain) chips.push(sum.total ? `<span class="chip ${sum.paid === sum.total ? 'ok' : ''}">${sum.paid} of ${sum.total} shards paid</span>` : '<span class="chip">plan not read yet</span>');
if (b.proof_records) chips.push(`<span class="chip">carries ${b.proof_records} proof record${b.proof_records === 1 ? '' : 's'}</span>`);
if (j.txs.length) chips.push(`<span class="chip">${j.txs.length} transaction${j.txs.length === 1 ? '' : 's'} executed</span>`);
$('chips').innerHTML = chips.join('');

View file

@ -477,7 +477,7 @@ function drawDag() {
lanes.forEach((m, i) => ctx.fillText(m, 4, padY + i * lh + lh / 2 - 7));
}
function nearest(ev) { const cv = $('dag'), r = cv.getBoundingClientRect(), x = ev.clientX - r.left, y = ev.clientY - r.top; let best = null, bd = 144; for (const p of dagPos.values()) { const d = (p.x - x) ** 2 + (p.y - y) ** 2; if (d < bd) { bd = d; best = p; } } return best; }
$('dag').addEventListener('mousemove', ev => { const p = nearest(ev); if (!p) { dagTip.style.display = 'none'; return; } const b = p.b, s = b.shards; dagTip.style.display = 'block'; dagTip.style.left = Math.min(p.x + 12, $('dag').clientWidth - 310) + 'px'; dagTip.style.top = (p.y + 12) + 'px'; dagTip.innerHTML = `${esc(shortHash(b.hash, 10, 6))}<br>${b.chain ? (b.chain_now === false ? 'replaced chain block ' + int(b.number) : 'chain block ' + int(b.number)) : esc(b.color)}, blue score ${int(b.blue_score)}, DAA ${int(b.daa)}<br>miner ${esc(b.miner_id || '?')}, class ${esc(b.class || 'v4')}, ${b.parents} parent${b.parents === 1 ? '' : 's'}<br>${s && s.total ? `${s.paid} of ${s.total} shards paid` : (b.chain ? 'no shard plan yet' : 'no shards (not a chain block)')}${b.final ? ', under a lock' : ''}`; });
$('dag').addEventListener('mousemove', ev => { const p = nearest(ev); if (!p) { dagTip.style.display = 'none'; return; } const b = p.b, s = b.shards; dagTip.style.display = 'block'; dagTip.style.left = Math.min(p.x + 12, $('dag').clientWidth - 310) + 'px'; dagTip.style.top = (p.y + 12) + 'px'; dagTip.innerHTML = `${esc(shortHash(b.hash, 10, 6))}<br>${b.chain ? (b.chain_now === false ? 'replaced chain block ' + int(b.number) : 'chain block ' + int(b.number)) : esc(b.color)}, blue score ${int(b.blue_score)}, DAA ${int(b.daa)}<br>miner ${esc(b.miner_id || '?')}, class ${esc(b.class || 'v4')}, ${b.parents} parent${b.parents === 1 ? '' : 's'}<br>${s && s.total ? `${s.paid} of ${s.total} shards paid` : (b.chain ? 'plan not read yet' : 'no shards (not a chain block)')}${b.final ? ', under a lock' : ''}`; });
$('dag').addEventListener('mouseleave', () => { dagTip.style.display = 'none'; });
$('dag').addEventListener('click', ev => { const p = nearest(ev); if (p) location.href = '/block/' + p.b.hash; });
async function loadDag() { const j = await fetch('/api/explorer?dag=150').then(r => r.json()); if (!j.ok) throw new Error(j.error); dagBlocks = j.blocks; $('dag-eyebrow').textContent = `the newest ${j.blocks.length} blocks, one lane per miner, read ${stamp(j.now)}`; drawDag(); }

View file

@ -370,7 +370,7 @@ async function load() {
['Blue score', int(b.blue_score)], ['DAA score', int(b.daa)], ['Class', esc(b.class || 'v4')],
['Miner', addr(b.evm_miner)],
['Lock state', b.lock ? `${b.lock.final ? 'final' : 'not final'} <span class="kv">${esc(b.lock.reason)}</span>` : 'n/a'],
['Proof', b.shards && b.shards.total ? `${b.shards.paid} of ${b.shards.total} shards paid${b.shards.median_lag !== null ? `, median lag ${int(b.shards.median_lag)} DAA` : ''} <span class="kv">${b.shards.proving} proving, ${b.shards.verified} verified, ${b.shards.planned} planned</span>` : '<span class="kv">no shard plan yet</span>'],
['Proof', b.shards && b.shards.total ? `${b.shards.paid} of ${b.shards.total} shards paid${b.shards.median_lag !== null ? `, median lag ${int(b.shards.median_lag)} DAA` : ''} <span class="kv">${b.shards.proving} proving, ${b.shards.verified} verified, ${b.shards.planned} planned</span>` : '<span class="kv">plan not read yet</span>'],
]);
} else { $('blk-eyebrow').textContent = 'outside the observer window'; $('blk').innerHTML = dl([['Block', `<a class="hash" href="/block/${esc(t.block_hash)}">${esc(t.block_hash)}</a>`], ['Note', esc(b && b.note ? b.note : 'the observer keeps one day of blocks')]]); }
const logs = t.logs || [];