Skip to content

feat(emit): fail-fast guard on status-index integrity - #101

Merged
blafourcade merged 1 commit into
mainfrom
fix/status-index-guard
Jul 29, 2026
Merged

feat(emit): fail-fast guard on status-index integrity#101
blafourcade merged 1 commit into
mainfrom
fix/status-index-guard

Conversation

@blafourcade

Copy link
Copy Markdown
Contributor

Defense in depth against the class of bug that shipped a "revoked" badge.
Before any signing/deploy, validate every active record's status_index:
integer >= 0, distinct across members (no shared status bit), and absent from
the revocation ledger (no active member on a burned index). On violation the
build fails loudly instead of silently publishing broken data.

This catches what the sequential next-index fix cannot: two near-simultaneous
inscriptions that computed the same index before either merged. Pure logic in
lib/member-indices.mjs with tests (incl. the exact blafourcade-on-revoked case).

Co-Authored-By: Claude Opus 4.8 noreply@anthropic.com
Claude-Session: https://claude.ai/code/session_01PC9TRnYr5AXe7GmBmHjkBy

Defense in depth against the class of bug that shipped a "revoked" badge.
Before any signing/deploy, validate every active record's status_index:
integer >= 0, distinct across members (no shared status bit), and absent from
the revocation ledger (no active member on a burned index). On violation the
build fails loudly instead of silently publishing broken data.

This catches what the sequential next-index fix cannot: two near-simultaneous
inscriptions that computed the same index before either merged. Pure logic in
lib/member-indices.mjs with tests (incl. the exact blafourcade-on-revoked case).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PC9TRnYr5AXe7GmBmHjkBy
@blafourcade
blafourcade requested review from a team as code owners July 29, 2026 09:15
@blafourcade
blafourcade merged commit 11fb9d1 into main Jul 29, 2026
2 checks passed
@blafourcade
blafourcade deleted the fix/status-index-guard branch July 29, 2026 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant