summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mailman/docs/NEWS.rst1
-rw-r--r--src/mailman/runners/digest.py13
-rw-r--r--src/mailman/runners/docs/digester.rst13
3 files changed, 19 insertions, 8 deletions
diff --git a/src/mailman/docs/NEWS.rst b/src/mailman/docs/NEWS.rst
index 301703d52..b92d57068 100644
--- a/src/mailman/docs/NEWS.rst
+++ b/src/mailman/docs/NEWS.rst
@@ -56,6 +56,7 @@ Documentation
Bug fixes
---------
+ * Fixed the RFC 1153 digest footer to be compliant. (LP: #887610)
* Fixed a UnicodeError with non-ascii message bodies in the `approved` rule,
given by Mark Sapiro. (LP: #949924)
* Fixed a typo when returning the configuration file's header match checks.
diff --git a/src/mailman/runners/digest.py b/src/mailman/runners/digest.py
index afc11f732..c347667f8 100644
--- a/src/mailman/runners/digest.py
+++ b/src/mailman/runners/digest.py
@@ -284,16 +284,17 @@ class RFC1153Digester(Digester):
self._mlist.fqdn_listname,
self._mlist.digest_footer_uri))
footer_text = ''
- # This is not strictly conformant RFC 1153. The trailer is only
- # supposed to contain two lines, i.e. the "End of ... Digest" line
- # and the row of asterisks. If this screws up MUAs, the solution
- # is to add the footer as the last message in the RFC 1153 digest.
- # I just hate the way that VM does that and I think it's confusing
- # to users, so don't do it unless there's a clamor.
+ # MAS: There is no real place for the digest_footer in an RFC 1153
+ # compliant digest, so add it as an additional message with
+ # Subject: Digest Footer
print >> self._text, self._separator30
print >> self._text
+ print >> self._text, 'Subject: ' + _('Digest Footer')
+ print >> self._text
print >> self._text, footer_text
print >> self._text
+ print >> self._text, self._separator30
+ print >> self._text
# Add the sign-off.
sign_off = _('End of ') + self._digest_id
print >> self._text, sign_off
diff --git a/src/mailman/runners/docs/digester.rst b/src/mailman/runners/docs/digester.rst
index 1ca51bdae..42004bf06 100644
--- a/src/mailman/runners/docs/digester.rst
+++ b/src/mailman/runners/docs/digester.rst
@@ -265,12 +265,16 @@ The RFC 1153 contains the digest in a single plain text message.
<BLANKLINE>
------------------------------
<BLANKLINE>
+ Subject: Digest Footer
+ <BLANKLINE>
_______________________________________________
Test mailing list
test@example.com
http://lists.example.com/listinfo/test@example.com
<BLANKLINE>
<BLANKLINE>
+ ------------------------------
+ <BLANKLINE>
End of Test Digest, Vol 1, Issue 1
**********************************
<BLANKLINE>
@@ -425,8 +429,9 @@ The content can be decoded to see the actual digest text.
# We must display the repr of the decoded value because doctests cannot
# handle the non-ascii characters.
- >>> [repr(line)
- ... for line in rfc1153.msg.get_payload(decode=True).splitlines()]
+ >>> import pprint
+ >>> print pprint.pformat([repr(line)
+ ... for line in rfc1153.msg.get_payload(decode=True).splitlines()])
["'Envoyez vos messages pour la liste Test \\xc3\\xa0'",
"'\\ttest@example.com'",
"''",
@@ -459,12 +464,16 @@ The content can be decoded to see the actual digest text.
"''",
"'------------------------------'",
"''",
+ "'Subject: Pied de page des remises group\\xc3\\xa9es'",
+ "''",
"'_______________________________________________'",
"'Test mailing list'",
"'test@example.com'",
"'http://lists.example.com/listinfo/test@example.com'",
"''",
"''",
+ "'------------------------------'",
+ "''",
"'Fin de Groupe Test, Vol 1, Parution 2'",
"'*************************************'"]