From 8c1fa18658dc730b53ddbb4766549a4fe595e453 Mon Sep 17 00:00:00 2001 From: bwarsaw Date: Wed, 30 May 2007 17:14:09 +0000 Subject: Remove leftover reference to removed Mailman.database.tables.languages module. Add in a temporary reference (with XXX comment) to Mailman.database.model.Language where necessary, although I will need to remove this eventually. Added clean up code to the mlist-rosters.txt doctest, otherwise it leaks the test mailing list. --- Mailman/Gui/Language.py | 1 - Mailman/MailList.py | 3 ++- Mailman/docs/mlist-rosters.txt | 9 +++++++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/Mailman/Gui/Language.py b/Mailman/Gui/Language.py index 7b7433232..c29894fde 100644 --- a/Mailman/Gui/Language.py +++ b/Mailman/Gui/Language.py @@ -23,7 +23,6 @@ from Mailman import Utils from Mailman import i18n from Mailman import mm_cfg from Mailman.Gui.GUIBase import GUIBase -from Mailman.database.tables.languages import Language _ = i18n._ diff --git a/Mailman/MailList.py b/Mailman/MailList.py index 343040157..0e57aa0a8 100644 --- a/Mailman/MailList.py +++ b/Mailman/MailList.py @@ -51,7 +51,6 @@ from Mailman import Version from Mailman import database from Mailman.UserDesc import UserDesc from Mailman.configuration import config -from Mailman.database.tables.languages import Language from Mailman.interfaces import * # Base classes @@ -1417,6 +1416,8 @@ bad regexp in bounce_matching_header line: %s # Multilingual (i18n) support # def set_languages(self, *language_codes): + # XXX FIXME not to use a database entity directly. + from Mailman.database.model import Language # Don't use the language_codes property because that will add the # default server language. The effect would be that the default # server language would never get added to the list's list of diff --git a/Mailman/docs/mlist-rosters.txt b/Mailman/docs/mlist-rosters.txt index 490a07e0c..096ceb7d2 100644 --- a/Mailman/docs/mlist-rosters.txt +++ b/Mailman/docs/mlist-rosters.txt @@ -116,3 +116,12 @@ moderators. ... addresses.append(address.address) >>> sorted(addresses) ['aperson@example.com', 'bperson@example.com', 'cperson@example.com'] + + +Clean up +-------- + + >>> config.list_manager.delete(mlist) + >>> flush() + >>> [name for name in config.list_manager.names] + [] -- cgit v1.3.1