how to best trace the cause of notification emails sent by elgg that probably shouldn't be sent?

i have been informed that users are being notified of activity on my site that they shouldn't be notified of. for example, being notified of wire posts from people who are posting to their profile and who are not friends of the user receiving the notification. it appears that this may just be occurring when the notification recipient's friend is participating in a thread of wire posts.

in any case, i am attempting to debug this but it it isn't so straightforward to get the debug info. what's the most relied on way to debug email notifications? is there some kind of logging plugin for emails? thanks

  • On my dev server I disable cron and load /cron/minute manually. You can then set a breakpoint in elgg_send_email and walk up the call stack. That'll at least help a little.

    A debug mode for notifications would be great, even if it has to rely on hacks like debug_stacktrace().

  • right ok - i see. unfortunately, i haven't been able to reproduce the error away from my production site - but i'll come back to your tips if i get that far!