Moodle

Disable Email when over Bounce Threshold

Details

  • Type: New Feature New Feature
  • Status: Open Open
  • Priority: Minor Minor
  • Resolution: Unresolved
  • Affects Version/s: 1.9
  • Fix Version/s: None
  • Component/s: Libraries
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE

Description

Currently the bounce handling will stop sending mail to the address and prompt user to change their email address when they don't log in.

I added $CFG->disableemailwhenbounced (can change that name ) to change the behaviour to instead just disable email address when it bounces. (This is because we get users putting in bad email addresses when non exist).

Activity

Hide
Tim Lock added a comment -

Hi all,

I love the idea of this patch as we deal with universities with bounce messages for over quota and invalid email addresses. Maybe taking this further would be a cron script to re-enable email address after 48 hours so that forum emails could be attempted to be delivered again.

Are all versions of email servers handled with the admin/process_email.php?

Regards

Tim
NetSpot Pty Ltd

Show
Tim Lock added a comment - Hi all, I love the idea of this patch as we deal with universities with bounce messages for over quota and invalid email addresses. Maybe taking this further would be a cron script to re-enable email address after 48 hours so that forum emails could be attempted to be delivered again. Are all versions of email servers handled with the admin/process_email.php? Regards Tim NetSpot Pty Ltd
Hide
Penny Leach added a comment -

Sorry, I don't understand how this patch changes behaviour - all the patch seems to do is set email stop (which is a user preference that can be changed anyway), it doesn't change the fact that users won't get email if they've already had bounces, since that gets checked in email_to_user already?

Show
Penny Leach added a comment - Sorry, I don't understand how this patch changes behaviour - all the patch seems to do is set email stop (which is a user preference that can be changed anyway), it doesn't change the fact that users won't get email if they've already had bounces, since that gets checked in email_to_user already?
Hide
Dan Poltawski added a comment -

Sorry, my original description wasn't very good.

The difference is that the user doesn't get prompted to change their email address, we just disable it.

The reason for this is because a lot of users intentionally put rubbish in the email and don't disable it (this is because the students don't have email addresses). If we let them change to another they just put more rubbish in and the cycle continues.

Show
Dan Poltawski added a comment - Sorry, my original description wasn't very good. The difference is that the user doesn't get prompted to change their email address, we just disable it. The reason for this is because a lot of users intentionally put rubbish in the email and don't disable it (this is because the students don't have email addresses). If we let them change to another they just put more rubbish in and the cycle continues.
Hide
Penny Leach added a comment -

ah that makes sense. it seems reasonable to me! go ahead and put it in head.

Show
Penny Leach added a comment - ah that makes sense. it seems reasonable to me! go ahead and put it in head.
Hide
Penny Leach added a comment -

(with appropriate change to config-dist)

Show
Penny Leach added a comment - (with appropriate change to config-dist)
Hide
Penny Leach added a comment -

Tim - the original patch uses a bounce threshold which sort of takes care of that - you can say that they only need one bounce to trigger disabling the email or define a threshold. I agree, you could optionally let cron re-enable them again... if you prepare a patch for this I could look at merging it.

About the email server question - there should be sufficient documentation here: http://docs.moodle.org/en/Email_processing

Show
Penny Leach added a comment - Tim - the original patch uses a bounce threshold which sort of takes care of that - you can say that they only need one bounce to trigger disabling the email or define a threshold. I agree, you could optionally let cron re-enable them again... if you prepare a patch for this I could look at merging it. About the email server question - there should be sufficient documentation here: http://docs.moodle.org/en/Email_processing

People

Vote (3)
Watch (4)

Dates

  • Created:
    Updated: