Hi
I can't seem to be able to add bans via mailman-shell: # mailman-wrapper shell Welcome to the GNU Mailman shell >>> from mailman.testing.documentation import dump_json >>> from mailman.interfaces.mailinglist import IMailingList >>> from zope.component import getUtility >>> list_manager = getUtility(IListManager) >>> mlist = list_manager.get('x2go-comm...@lists.x2go.org') >>> bans = IBanManager(mlist)>>> new_bans = ["really", "long", "list", "with", "addresses", "I'd", "like", "to", "ban"]
>>> for new_ban in new_bans: ... bans.ban(new_ban) ... >>> for ban in bans: ... print('{0}: {1}'.format(ban.list_id,ban.email)) ... [long list of bans] >>> exit() # mailman-wrapper shell Welcome to the GNU Mailman shell >>> from mailman.testing.documentation import dump_json >>> from mailman.interfaces.mailinglist import IMailingList >>> from zope.component import getUtility >>> list_manager = getUtility(IListManager) >>> mlist = list_manager.get('x2go-comm...@lists.x2go.org') >>> bans = IBanManager(mlist) >>> for ban in bans: ... print('{0}: {1}'.format(ban.list_id,ban.email)) ... >>> exit()GNU Mailman 3.3.8 (Tom Sawyer), installed on Ubuntu 24.04 via distro packages (yes, they are completely broken; yes, I had to backport fixes from your Gitlab instance to even get this properly installed and working; yes, I think I can handle this)
What could possibly be the cause of this? I don't even see any calls to the REST API for each bans.ban() call. Should I see those? Or is bans.ban() directly modifying the database? I skimmed the source code and it looks like as if IBanManager and the concrete BanManager model seem to work directly on a DB connection, so I assume that it's not going through REST. If that is the case (I'm using sqlite3, nothing fancy), why doesn't it stick? Do I have to commit changes somehow?
Mihai
OpenPGP_signature.asc
Description: OpenPGP digital signature
_______________________________________________ Mailman-users mailing list -- mailman-users@mailman3.org To unsubscribe send an email to mailman-users-le...@mailman3.org https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/FK5OJJDXYTY4ADWZE6OPJDNDCKYUTEE3/ This message sent to arch...@mail-archive.com