feat(indexer): index binary-version attestations (0.19 reportUri is event-only)#205
Conversation
…vent-only) tnt-core 0.19 removed reportUri from the on-chain Attestation struct (event-only now), and attestations were never indexed. Add a BinaryVersionAttestation entity materialized from BinaryVersionAttested (carries reportUri, kind, severity) + BinaryVersionAttestationRevoked (sets revoked/revokedAt/reasonUri), mirroring the existing BinaryVersionRecorded indexing. kind stored as a readable enum with an UNKNOWN fallback so an appended on-chain variant never breaks indexing. Subscribed on both config.yaml and config.local.yaml. codegen + build green. Unblocks the dapp's attestation UI on 0.19 chains (reportUri now comes from the indexer, not the now-lossy getAttestation view).
tangletools
left a comment
There was a problem hiding this comment.
✅ Auto-approved drewstone PR — fc490fe8
This PR was opened by the trusted drewstone account.
The full PR reviewer audit still runs separately and will publish findings if it detects issues.
tangletools · auto-approval · reason: drewstone_author · 2026-07-07T20:31:42Z
tangletools
left a comment
There was a problem hiding this comment.
⚪ Value Audit — audit-incomplete
| Verdict | audit-incomplete |
| Concerns | 0 (none) |
| Heuristic | 0.0s |
| Duplication | 0.0s |
| Interrogation | 20.6s (2 bridge agents) |
| Total | 20.6s |
💰 Value — error
value agent produced no parseable value-audit JSON.
- Model: opencode/deepseek/deepseek-v4-pro
- Bridge attempts: 3
- Bridge error: opencode/kimi-for-coding/k2p7: bridge stream ended without value-audit content; opencode/zai-coding-plan/glm-5.2: bridge stream ended without value-audit content; opencode/deepseek/deepseek-v4-pro: bridge stream ended without value-audit content
🎯 Usefulness — error
usefulness agent produced no parseable value-audit JSON.
- Model: opencode/deepseek/deepseek-v4-pro
- Bridge attempts: 3
- Bridge error: opencode/zai-coding-plan/glm-5.2: bridge stream ended without value-audit content; opencode/kimi-for-coding/k2p7: bridge stream ended without value-audit content; opencode/deepseek/deepseek-v4-pro: bridge stream ended without value-audit content
No PR concerns were produced because the value/usefulness agent pass did not complete. Treat this audit as incomplete, not as approval.
What this audit checks
It judges the change on its merits — not whether it was tasked out in an issue. Unticketed, fast-moving work is fine; the question is whether the change is good and whether a better or existing approach should be used instead.
| Pass | What it asks |
|---|---|
| Heuristic | Vague title? Whitespace-only or cruft-bearing diff? (content signals only) |
| Duplication | Do added function/class names already exist elsewhere in the repo? |
| Value Audit | What does it do? What goal does it achieve? Is it good? Better architecture or already-exists? |
| Usefulness Audit | Does it integrate and fit? Will it hold up in real use and actually get used? |
Findings are concerns, not blocks — the human reviewer decides what to do with them.
0.19 removed
reportUrifrom the on-chainAttestationstruct (event-only), and attestations were never indexed. Adds aBinaryVersionAttestationentity materialized fromBinaryVersionAttested(reportUri/kind/severity) +BinaryVersionAttestationRevoked, mirroring the existingBinaryVersionRecordedindexing.kindstored as a readable enum with UNKNOWN fallback. Subscribed on both config files. codegen + build green. Unblocks the dapp's attestation UI on 0.19 (reportUri now from the indexer, not the lossy view). The other view→event fields the dapp needs (binaryUri, slash disputeReason/disputedAt/proposedAt) were already event-sourced by #196/#202 — no change needed there.