Skip to content

[pull] main from forem:main#323

Merged
pull[bot] merged 1 commit into
amishakov:mainfrom
forem:main
Jul 8, 2026
Merged

[pull] main from forem:main#323
pull[bot] merged 1 commit into
amishakov:mainfrom
forem:main

Conversation

@pull

@pull pull Bot commented Jul 8, 2026

Copy link
Copy Markdown

See Commits and Changes for more details.


Created by pull[bot] (v2.0.0-alpha.4)

Can you help keep this open source service alive? 💖 Please sponsor : )

…DP (#23574)

* Emit DEV moderation events to the Customer.io CDP

Suspending, spam-flagging, or banishing a user (and the reversals) now
emits user_suspended / user_spam_flagged / user_banished /
user_unsuspended / user_spam_unflagged through the existing Trackable
pipeline, so MLH Core can scope the DEV newsletter and prune bot
Customer.io profiles. Emission goes through add_role/remove_role (the
single choke point for every moderation path) and only fires on actual
role transitions; banish also emits explicitly with the pre-banish
username. Same gates as the rest of the DEV → Core sync:
customerio_cdp_enabled + the dev_core_user_sync feature flag.

* Emit user_gdpr_deleted to the DEV → Core sync on account deletion

Users::DeleteWorker is the single choke point for both self-service and
admin deletions (it already records the GDPRDeleteRequest), so the
event is emitted there after the destroy. Core uses it to erase the
DEV-derived data it holds — and to delete DEV-only user records and
their Customer.io profiles entirely.

* Suppress the banish-internal user_suspended emission

Banish grants the suspended role via handle_user_status, which the new
add_role override would emit as user_suspended alongside user_banished.
The two events race through the CDP: if user_suspended lands second,
Core's moderation marker downgrades from banished to suspended after
the CIO prune already ran. Wrapping the role grant in
User.skip_trackable_events makes banish a single user_banished event.
@pull pull Bot locked and limited conversation to collaborators Jul 8, 2026
@pull pull Bot added the ⤵️ pull label Jul 8, 2026
@pull pull Bot merged commit f6dea2b into amishakov:main Jul 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant