diff --git a/mailman.spec b/mailman.spec index a6422bc..276877b 100644 --- a/mailman.spec +++ b/mailman.spec @@ -7,7 +7,7 @@ Name: mailman Version: 3.3.2 -Release: 4 +Release: 5 Epoch: 3 Summary: The GNU mailing list manager License: GPLv3 @@ -19,6 +19,8 @@ Source3: mailman3.service Source4: mailman3.logrotate Source5: mailman3-digests.service Source6: mailman3-digests.timer +#Refer: https://gitlab.com/mailman/mailman/-/merge_requests/860 +Patch01: mailman3-click8.patch Patch11: mailman-subject-prefix.patch Patch14: mailman-use-either-importlib_resources-or-directly-importlib.patch #Refer: https://bugzilla.redhat.com/show_bug.cgi?id=1900668#c9 @@ -206,6 +208,9 @@ done %{_datadir}/selinux/*/mailman3.pp %changelog +* Tue May 24 2022 wulei - 3:3.3.2-5 +- Require click >=8.0.0 and fix the tests it breaks + * Fri May 13 2022 caodongxia - 3:3.3.2-4 - Fix test_interact and test_message failure diff --git a/mailman3-click8.patch b/mailman3-click8.patch new file mode 100644 index 0000000..91fcf76 --- /dev/null +++ b/mailman3-click8.patch @@ -0,0 +1,107 @@ +From 465c2ff847d462c1a9cf8f548093ba4b5be84c3b Mon Sep 17 00:00:00 2001 +From: Mark Sapiro +Date: Tue, 11 May 2021 18:14:59 -0700 +Subject: [PATCH] Require click >=8.0.0 and fix the tests it breaks. + +--- + setup.py | 2 +- + src/mailman/commands/docs/import.rst | 1 + + src/mailman/commands/tests/test_cli_addmembers.py | 8 ++++---- + src/mailman/commands/tests/test_cli_delmembers.py | 4 ++-- + src/mailman/commands/tests/test_cli_syncmembers.py | 8 ++++---- + 5 files changed, 12 insertions(+), 11 deletions(-) + +diff --git a/setup.py b/setup.py +index cd36456..ad04e77 100644 +--- a/setup.py ++++ b/setup.py +@@ -115,7 +115,7 @@ case second 'm'. Any other spelling is incorrect.""", + 'atpublic', + 'authheaders>=0.9.2', + 'authres>=1.0.1', +- 'click>=7.0.0', ++ 'click>=8.0.0', + 'dnspython>=1.14.0', + 'falcon>1.0.0', + 'flufl.bounce', +diff --git a/src/mailman/commands/docs/import.rst b/src/mailman/commands/docs/import.rst +index 947d932..66f72be 100644 +--- a/src/mailman/commands/docs/import.rst ++++ b/src/mailman/commands/docs/import.rst +@@ -58,5 +58,6 @@ import, the mailing list's "real name" will change. + Import + + >>> command('mailman import21 import@example.com ' + pickle_file) ++ Importing ... + >>> print(mlist.display_name) + Test +diff --git a/src/mailman/commands/tests/test_cli_addmembers.py b/src/mailman/commands/tests/test_cli_addmembers.py +index e257da5..95f8542 100644 +--- a/src/mailman/commands/tests/test_cli_addmembers.py ++++ b/src/mailman/commands/tests/test_cli_addmembers.py +@@ -57,8 +57,8 @@ class TestCLIAddMembers(unittest.TestCase): + result.output, + 'Usage: addmembers [OPTIONS] FILENAME LISTSPEC\n' + 'Try \'addmembers --help\' for help.\n\n' +- 'Error: Invalid value for \'FILENAME\': Could not open ' +- 'file: bad: No such file or directory\n') ++ 'Error: Invalid value for \'FILENAME\': ' ++ '\'bad\': No such file or directory\n') + + def test_already_subscribed_with_display_name(self): + subscribe(self._mlist, 'Anne') +@@ -265,8 +265,8 @@ class TestCLIAddMembers(unittest.TestCase): + 'Usage: addmembers [OPTIONS] FILENAME LISTSPEC\n' + 'Try \'addmembers --help\' for help.\n\n' + 'Error: Invalid value for \'--delivery\' / \'-d\': ' +- 'invalid choice: bogus. (choose from regular, mime, ' +- 'plain, summary, disabled)\n') ++ '\'bogus\' is not one of \'regular\', \'mime\', ' ++ '\'plain\', \'summary\', \'disabled\'.\n') + + def test_invite_member(self): + with NamedTemporaryFile('w', buffering=1, encoding='utf-8') as infp: +diff --git a/src/mailman/commands/tests/test_cli_delmembers.py b/src/mailman/commands/tests/test_cli_delmembers.py +index cf24b54..e34c22a 100644 +--- a/src/mailman/commands/tests/test_cli_delmembers.py ++++ b/src/mailman/commands/tests/test_cli_delmembers.py +@@ -56,8 +56,8 @@ class TestCLIDelMembers(unittest.TestCase): + result.output, + 'Usage: delmembers [OPTIONS]\n' + 'Try \'delmembers --help\' for help.\n\n' +- 'Error: Invalid value for \'--file\' / \'-f\': Could not open ' +- 'file: bad: No such file or directory\n') ++ 'Error: Invalid value for \'--file\' / \'-f\': ' ++ '\'bad\': No such file or directory\n') + + def test_not_subscribed_without_display_name(self): + with NamedTemporaryFile('w', buffering=1, encoding='utf-8') as infp: +diff --git a/src/mailman/commands/tests/test_cli_syncmembers.py b/src/mailman/commands/tests/test_cli_syncmembers.py +index 658b867..faed507 100644 +--- a/src/mailman/commands/tests/test_cli_syncmembers.py ++++ b/src/mailman/commands/tests/test_cli_syncmembers.py +@@ -58,8 +58,8 @@ class TestCLISyncMembers(unittest.TestCase): + result.output, + 'Usage: syncmembers [OPTIONS] FILENAME LISTSPEC\n' + 'Try \'syncmembers --help\' for help.\n\n' +- 'Error: Invalid value for \'FILENAME\': Could not open ' +- 'file: bad: No such file or directory\n') ++ 'Error: Invalid value for \'FILENAME\': ' ++ '\'bad\': No such file or directory\n') + + def test_sync_invalid_email(self): + with NamedTemporaryFile('w', buffering=1, encoding='utf-8') as infp: +@@ -374,8 +374,8 @@ class TestCLISyncMembers(unittest.TestCase): + 'Usage: syncmembers [OPTIONS] FILENAME LISTSPEC\n' + 'Try \'syncmembers --help\' for help.\n\n' + 'Error: Invalid value for \'--delivery\' / \'-d\': ' +- 'invalid choice: bogus. (choose from regular, mime, ' +- 'plain, summary, disabled)\n') ++ '\'bogus\' is not one of \'regular\', \'mime\', ' ++ '\'plain\', \'summary\', \'disabled\'.\n') + + def test_override_no_welcome(self): + self._mlist.send_welcome_message = False +-- +2.32.0 +