Mark Sapiro pushed to branch master at GNU Mailman / Mailman Core
Commits: 8c6f506b by Mark Sapiro at 2021-06-19T14:44:12-07:00 Commit successful member deletions in bounce processing. - - - - - 17d8abd5 by Mark Sapiro at 2021-06-19T22:36:41+00:00 Merge branch 'bounce' into 'master' Commit successful member deletions in bounce processing. Closes #909 See merge request mailman/mailman!879 - - - - - 2 changed files: - src/mailman/docs/NEWS.rst - src/mailman/model/bounce.py Changes: ===================================== src/mailman/docs/NEWS.rst ===================================== @@ -77,7 +77,8 @@ Bugs forwarded. (closes #914) * Dispose SQLAlchemy connections after a new worker process is forked. (Closes #854) - +* Exceptions in bounce processing member removal don't roll back successful + removals. (Closes #909) Command line ------------ ===================================== src/mailman/model/bounce.py ===================================== @@ -29,7 +29,8 @@ from mailman.app.notifications import ( send_admin_removal_notice, send_user_disable_warning) from mailman.config import config from mailman.database.model import Model -from mailman.database.transaction import dbconnection, transactional +from mailman.database.transaction import ( + dbconnection, transaction, transactional) from mailman.database.types import Enum, SAUnicode from mailman.interfaces.bounce import ( BounceContext, IBounceEvent, IBounceProcessor, InvalidBounceEvent) @@ -267,9 +268,10 @@ class BounceProcessor: admin_notif = False send_admin_notif = True - delete_member( - mlist=member._mailing_list, email=member.address.email, - admin_notif=admin_notif, userack=True) + with transaction(): + delete_member( + mlist=member._mailing_list, email=member.address.email, + admin_notif=admin_notif, userack=True) if send_admin_notif: send_admin_removal_notice( View it on GitLab: https://gitlab.com/mailman/mailman/-/compare/f67aa774fd515e99c06ba02a2c176ab161c81af4...17d8abd5afddd97540a73223fc875a5b0093f147 -- View it on GitLab: https://gitlab.com/mailman/mailman/-/compare/f67aa774fd515e99c06ba02a2c176ab161c81af4...17d8abd5afddd97540a73223fc875a5b0093f147 You're receiving this email because of your account on gitlab.com.
_______________________________________________ Mailman-checkins mailing list -- mailman-checkins@python.org To unsubscribe send an email to mailman-checkins-le...@python.org https://mail.python.org/mailman3/lists/mailman-checkins.python.org/ Member address: arch...@jab.org