summaryrefslogtreecommitdiff
path: root/mailman/bin/inject.py
diff options
context:
space:
mode:
authorBarry Warsaw2008-03-30 19:38:18 -0400
committerBarry Warsaw2008-03-30 19:38:18 -0400
commit0e1c2be3e6110ccece3cbd0ebc5bfd0eb76c3aad (patch)
treec0432554f9bb4068b6bae6e3a83ddde925c0cd4f /mailman/bin/inject.py
parent7f440dc39489b32257c35f15ee6f27d90a197cf5 (diff)
downloadmailman-0e1c2be3e6110ccece3cbd0ebc5bfd0eb76c3aad.tar.gz
mailman-0e1c2be3e6110ccece3cbd0ebc5bfd0eb76c3aad.tar.zst
mailman-0e1c2be3e6110ccece3cbd0ebc5bfd0eb76c3aad.zip
More fixes to get end-to-end delivery basically working.
- Add a VirginPipeline for the virgin queue, which is mostly the same as the BuiltInPipeline, so refactor the commonality into a BasePipeline. - Simplify and update bin/dumpdb. - Rename inject() to inject_text() and add inject_message(). Both interfaces will be useful. - When enqueuing and not using _plaintext, use the highest pickle protocol supported. - Fix the archive runner's calculation of whether to clobber the message's Date: header. - Fix the outgoing queue's deliver_after calculation. - Update the virgin queue runner. It doesn't need to inherit from IncomingRunner any more; it can just execute the 'virgin' pipeline.
Diffstat (limited to 'mailman/bin/inject.py')
-rw-r--r--mailman/bin/inject.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/mailman/bin/inject.py b/mailman/bin/inject.py
index 3e4012baf..8c4613756 100644
--- a/mailman/bin/inject.py
+++ b/mailman/bin/inject.py
@@ -20,11 +20,14 @@ from __future__ import with_statement
import os
import sys
+from email import message_from_string
+
from mailman import Utils
from mailman import Version
+from mailman.Message import Message
from mailman.configuration import config
from mailman.i18n import _
-from mailman.inject import inject
+from mailman.inject import inject_text
from mailman.options import SingleMailingListOptions
@@ -81,7 +84,7 @@ def main():
with open(options.filename) as fp:
message_text = fp.read()
- inject(fqdn_listname, message_text, qdir=qdir)
+ inject_text(mlist, message_text, qdir=qdir)