block/buzz · error
mentions b-replica-only
Error message
mentions b-replica-only
What it means
Panic from `.expect("mentions b-replica-only")` seeding community B's replica-only mention fixture on the replica pool. Err indicates the mention insert failed on the replica database.
Source
Thrown at crates/buzz-db/src/runtime/tests.rs:1968
let b_replica_only = tagged("b-replica-only", base + 11);
insert_top_level(&replica, comm_a, chan_a, &a_replica_only).await;
insert_mentions(
&replica,
CommunityId::from_uuid(comm_a),
&a_replica_only,
Some(chan_a),
)
.await
.expect("mentions a-replica-only");
insert_top_level(&replica, comm_b, chan_b, &b_replica_only).await;
insert_mentions(
&replica,
CommunityId::from_uuid(comm_b),
&b_replica_only,
Some(chan_b),
)
.await
.expect("mentions b-replica-only");
// Needs-action fixtures: approval kind, replica-only in BOTH
// communities, so the assertion below is replica-served on A and
// must still not see B's.
let a_approval = tagged_kind(46010, "a-approval-replica-only", base + 20);
let b_approval = tagged_kind(46010, "b-approval-replica-only", base + 21);
insert_top_level(&replica, comm_a, chan_a, &a_approval).await;
insert_mentions(
&replica,
CommunityId::from_uuid(comm_a),
&a_approval,
Some(chan_a),
)
.await
.expect("mentions a-approval");
insert_top_level(&replica, comm_b, chan_b, &b_approval).await;
insert_mentions(
&replica,View on GitHub (pinned to dad5a33865)
Solutions
- Ensure b_replica_only's top-level event was inserted before its mention
- Confirm the replica pool connects and is migrated
- Log the sqlx error via unwrap_or_else for diagnosis
Example fix
// before
.await.expect("mentions b-replica-only");
// after
.await.unwrap_or_else(|e| panic!("mentions b-replica-only: {e}")); Defensive patterns
Strategy: try-catch
Validate before calling
sqlx::query("SELECT 1").execute(&replica).await?;
assert!(fetch_event(&replica, &b_replica_only.id).await.is_some()); Try / catch
insert_mentions(&replica, comm_b, &b_replica_only, Some(chan_b)).await
.unwrap_or_else(|e| panic!("mentions b-replica-only: {e}")); Prevention
- Same replica-health and ordering checks as other replica fixtures
- Isolate replica bootstrap in a helper that fails fast
- Surface sqlx error details instead of bare expect messages
When it happens
Trigger: insert_mentions(&replica, CommunityId::from_uuid(comm_b), &b_replica_only, Some(chan_b)) returns Err — replica connection failure, missing parent event, or schema/constraint mismatch.
Common situations: Replica scratch DB missing migrations or unreachable; fixture ordering issue where b_replica_only's top-level event insert failed first.
Related errors
AI-assisted analysis of block/buzz@dad5a33865 (2026-08-30).
Data as JSON: /api/errors/30dbb8432666abdc.
Report an issue: GitHub.