You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The {ok, SentTo} is constructed by the handler, not returned by the
operation. asobi_admin_notifications:do_broadcast/4 drops every failed
insert on the floor and returns only the survivors, so a broadcast to ten
players that reached three is logged as outcome => ok with recipient_count => 3. Nothing anywhere records that seven failed.
What core now provides
asobi core ships the durable audit and the widened contract (plan item 2a.8):
asobi_ops_notifications:broadcast/5 takes an actor, fans out, and writes
an ops_audit_entries row through asobi_ops_audit:mutation/4. It cannot
misreport, because the row is built from the operation's own return value.
The row carries actor_id, actor_display, actor_source and actor_attested, plus outcome (ok / partial / error) and the two
counts.
Work here
Delete asobi_admin_notifications:do_broadcast/4 - it is a copy of asobi_notify:send_many/4 and now a stale one.
Have the UI controller and asobi_admin_notifications:broadcast/1 call asobi_ops_notifications:broadcast/5, passing the session's actor.
Drop the hand-built {ok, SentTo} audit call at the broadcast site.
Decide what the UI shows on a partial send. The current redirect carries
only ?sent=N, which reads as a success.
asobi_admin has no actor record yet; it still pins one hardcoded principal.
Constructing an #{id, display, source, caps, attested} for the session is
part of this, or a prerequisite issue.
asobi_admin_notifications_controller:broadcast/1callsasobi_admin_ui_audit:log_action(~"broadcast", #{recipient_count => length(SentTo)}, {ok, SentTo}).The
{ok, SentTo}is constructed by the handler, not returned by theoperation.
asobi_admin_notifications:do_broadcast/4drops every failedinsert on the floor and returns only the survivors, so a broadcast to ten
players that reached three is logged as
outcome => okwithrecipient_count => 3. Nothing anywhere records that seven failed.What core now provides
asobi core ships the durable audit and the widened contract (plan item 2a.8):
asobi_notify:send_many/4returns{ok, Succeeded, Failed}.asobi_ops_notifications:broadcast/5takes an actor, fans out, and writesan
ops_audit_entriesrow throughasobi_ops_audit:mutation/4. It cannotmisreport, because the row is built from the operation's own return value.
actor_id,actor_display,actor_sourceandactor_attested, plusoutcome(ok/partial/error) and the twocounts.
Work here
asobi_admin_notifications:do_broadcast/4- it is a copy ofasobi_notify:send_many/4and now a stale one.asobi_admin_notifications:broadcast/1callasobi_ops_notifications:broadcast/5, passing the session's actor.{ok, SentTo}audit call at the broadcast site.only
?sent=N, which reads as a success.asobi_adminhas no actor record yet; it still pins one hardcoded principal.Constructing an
#{id, display, source, caps, attested}for the session ispart of this, or a prerequisite issue.