From 0d0c030d50e4dbd11f33ccddb96cf13fd3470cd2 Mon Sep 17 00:00:00 2001 From: Barry Warsaw Date: Sun, 13 Jan 2008 16:17:38 -0500 Subject: Add an interface IArchiver which is used to calculate urls and send messages to the archiver. Also add a plugin architecture for easily overriding the archiver, and hook this into the setup.py script. Updated CookHeaders.py and Scrubber.py handlers to use the plugged archiver. Updated doctests as appropriate. Fix a typo in the setup.py file. --- Mailman/docs/cook-headers.txt | 13 +++++++++++++ Mailman/docs/scrubber.txt | 16 ++++++++-------- 2 files changed, 21 insertions(+), 8 deletions(-) (limited to 'Mailman/docs') diff --git a/Mailman/docs/cook-headers.txt b/Mailman/docs/cook-headers.txt index 1b7705d1c..a6954e5c6 100644 --- a/Mailman/docs/cook-headers.txt +++ b/Mailman/docs/cook-headers.txt @@ -285,6 +285,19 @@ List-Archive header either. ---end--- +Archived-At +----------- + +RFC 5064 (draft) defines a new Archived-At header which contains the url to +the individual message in the archives. The stock Pipermail archiver doesn't +support this because the url can't be calculated until after the message is +archived. Because this is done by the archive runner, this information isn't +available to us now. + + >>> print msg['archived-at'] + None + + Personalization --------------- diff --git a/Mailman/docs/scrubber.txt b/Mailman/docs/scrubber.txt index e4259361d..564405378 100644 --- a/Mailman/docs/scrubber.txt +++ b/Mailman/docs/scrubber.txt @@ -59,9 +59,9 @@ this is an unfortunate double negative). ... ... R0lGODdhAQABAIAAAAAAAAAAACwAAAAAAQABAAACAQUAOw== ... """) - >>> save_attachment(mlist, msg, '') - u'' - >>> data = read_attachment('xtest.gif') + >>> save_attachment(mlist, msg, 'dir') + u'' + >>> data = read_attachment('dir/xtest.gif') >>> data[:6] 'GIF87a' >>> len(data) @@ -88,13 +88,13 @@ the Defaults.py.in file. ... ... R0lGODdhAQABAIAAAAAAAAAAACwAAAAAAQABAAACAQUAOw== ... """) - >>> save_attachment(mlist, msg, '') - u'' - >>> data = read_attachment('xtest.gif') + >>> save_attachment(mlist, msg, 'dir') + u'' + >>> data = read_attachment('dir/xtest.gif') Traceback (most recent call last): IOError: [Errno ...] No such file or directory: - u'.../archives/private/_xtest@example.com/xtest.gif' - >>> data = read_attachment('attachment.gif') + u'.../archives/private/_xtest@example.com/dir/xtest.gif' + >>> data = read_attachment('dir/attachment.gif') >>> data[:6] 'GIF87a' >>> len(data) -- cgit v1.3.1