From 510daed5ea265ba076c8850a670ec8de8ad50c56 Mon Sep 17 00:00:00 2001 From: Mark Sapiro Date: Sat, 1 Aug 2009 12:01:28 -0700 Subject: Fixed a bug that could cause incorrect threading of replies to archived messages that arrive with timestamps in the same second. --- Mailman/Archiver/pipermail.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'Mailman') diff --git a/Mailman/Archiver/pipermail.py b/Mailman/Archiver/pipermail.py index 49de805b..cfa4301e 100644 --- a/Mailman/Archiver/pipermail.py +++ b/Mailman/Archiver/pipermail.py @@ -122,9 +122,10 @@ class Database(DatabaseInterface): parentID = article.parentID if parentID is not None and self.articleIndex.has_key(parentID): parent = self.getArticle(archive, parentID) - myThreadKey = parent.threadKey + article.date + '-' + myThreadKey = (parent.threadKey + article.date + '.' + + str(article.sequence) + '-') else: - myThreadKey = article.date + '-' + myThreadKey = article.date + '.' + str(article.sequence) + '-' article.threadKey = myThreadKey key = myThreadKey, article.msgid self.setThreadKey(archive, key, article.msgid) @@ -418,7 +419,8 @@ class T: else: parent = self.database.getArticle(self.archive, article.parentID) - article.threadKey = parent.threadKey+article.date+'-' + article.threadKey = (parent.threadKey + article.date + '.' + + str(article.sequence) + '-') self.database.setThreadKey(self.archive, (article.threadKey, article.msgid), msgid) @@ -632,9 +634,11 @@ class T: article.parentID = parentID = self.get_parent_info(arch, article) if parentID: parent = self.database.getArticle(arch, parentID) - article.threadKey = parent.threadKey + article.date + '-' + article.threadKey = (parent.threadKey + article.date + '.' + + str(article.sequence) + '-') else: - article.threadKey = article.date + '-' + article.threadKey = (article.date + '.' + + str(article.sequence) + '-') key = article.threadKey, article.msgid self.database.setThreadKey(arch, key, article.msgid) -- cgit v1.2.3