On 10/16/24 07:02, Marco van Tol wrote:
On Wed, 16 Oct 2024 at 14:45, Marco van Tol <mvan...@ripe.net <mailto:mvan...@ripe.net>> wrote:

    The script went on its way for a bit, and then blew up.
    (attachment: error-run-1.txt)


I suspect the issue there is in the order of deletion and a message which is a parent in a thread gets deleted before the child.


I made a change to the script that's really blunt but does work.

See the attached change.  I can make it more efficient by calling the Email.objects.filter() once per loop instead of the current 2, but if you have any other improvements they'd be welcome.

I don't have any suggestions.


    And secondary: can I avoid the call to rebuild_index?  The actual
    production server has a massive count of messages.

If the massive count is distributed over multiple lists with not so many messages you can run the Django update_index_one_list job to just do one list.

--
Mark Sapiro <m...@msapiro.net>        The highway is for gamblers,
San Francisco Bay Area, California    better use your sense - B. Dylan

_______________________________________________
Mailman-Developers mailing list -- mailman-developers@python.org
To unsubscribe send an email to mailman-developers-le...@python.org
https://mail.python.org/mailman3/lists/mailman-developers.python.org/
Mailman FAQ: https://wiki.list.org/x/AgA3

Security Policy: https://wiki.list.org/x/QIA9

Reply via email to