Page MenuHomePhabricator

Omnimail unsubscribe processor fails on deleted contact_id
Open, Needs TriagePublic

Description

It seems there are some records in Acoustic whose contact_id points to an old contact that has been deleted in Civi (usually merged and marked is_deleted, then fully deleted by the 'delete deleted contacts' job). When one of them unsubscribes we get new rows in the mailing_provider_data table with a contact_id that the unsubscribe processor can't find.

It could instead search by email address and opt out all contacts with a matching primary email.