On 8/8/25 09:59, Morris Jones wrote:
But pendingdb.evict() doesn't seem to clear the list. For example, on
one of my lists:
>>> from mailman.interfaces.pending import IPendings
>>>
>>> from zope.component import getUtility
>>>
>>> pendingdb = getUtility(IPendings)
>>> pendingdb.count()
5040
>>> pendingdb.evict()
>>> pendingdb.count()
5040
>>>
pendingdb.evict() only deletes expired pendings, but by default
subscriptions pending confirmation expire after 3 days, but this is set
by pending_request_life in the [mailman] section of mailman.cfg. Have
you set that to a long time?
On the other hand in Mailman 3.3.2, subscriptions pending approval were
pended with a 10 year lifetime. This was changed in 3.3.5 to a new
moderator_request_life setting (default 180 days).
If you just want to delete all pendings you could do
```
pendingdb = getUtility(IPendings)
for pending in pendingdb:
pendingdb.confirm(pending[0], expunge=True)
# and if doing this in mailman shell
commit()
--
Mark Sapiro <m...@msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
_______________________________________________
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/GWUFQ2DRYFE4FGRURLEHGQBTIR36Z42B/
This message sent to arch...@mail-archive.com