summaryrefslogtreecommitdiff
path: root/src/mailman/app/moderator.py
Commit message (Collapse)AuthorAgeFilesLines
* Ensure the held message subject is a string.Mark Sapiro2017-05-241-1/+2
|
* Bump copyright years.Barry Warsaw2017-01-041-1/+1
|
* Merge gitlab.com:mailman/mailman into to_moderatorsMark Sapiro2016-12-041-1/+1
|\
| * Use `atpublic` for @public instead of internal copy.Barry Warsaw2016-11-291-1/+1
| |
* | Remove to_moderators.Mark Sapiro2016-12-041-1/+1
|/
* Closes: #68Barry Warsaw2016-11-131-1/+1
| | | | | Messages sent to the list's moderators now include the actual recipient addresses. Given by Tom Briles.
* Rebase mailman/mailman!180 and cleanup # noqaBarry Warsaw2016-07-281-1/+1
|
* New template system. Closes #249Barry Warsaw2016-07-161-16/+20
| | | | | The new template system is introduced for API 3.1. See ``src/mailman/rest/docs/templates.rst`` for details.
* Don't use `flake8: noqa`.Barry Warsaw2016-04-011-1/+1
| | | | | | | This suppresses all errors in the file. Use `noqa`, although pep8 doesn't honor this for all errors. There may be a plugin which helps.
* First massive round of cleanups.Barry Warsaw2016-03-231-17/+8
| | | | | | | | * Get rid of explicit __all__ settings and use the @public decorator. * Get rid of ^L's * Use expected_count argument for get_queue_messages() * Various code modernizations. * Other minor changes to make flake8 happy.
* Fix cross-posting held on more than one list.Barry Warsaw2016-03-081-6/+5
| | | | | | | | | | | Closes #176 Also: * IMessageStore no longer raises a ValueError if the Message-ID already exists in the store; it just returns None. * The internal handle_message() function no longer takes a `preserve` argument, since messages are never removed from the IMessageStore.
* Happy New Year.Barry Warsaw2016-01-021-1/+1
|
* Remove old APIs handle_subscription() and hold_subscription().Barry Warsaw2015-05-021-80/+3
|
* Merge branch '1-admin-notify-mchanges' into 'release-3.0'Barry Warsaw2015-05-021-5/+0
| | | | | | | | Honor admin_notify_mchanges with subscription policy When the mailing list's `admin_notify_mchanges` is True, the list owners now get the subscription notification. (Closes: #1) See merge request !4
* Branch his ready.Barry Warsaw2015-04-171-9/+13
|
* * Refactor add_member() so that it uses a RequestRecord namedtuple.Barry Warsaw2015-03-211-28/+29
| | | | | | * RequestRecord contains no password key so these are not part of the held requests database any more. * Pending record contains `email` now instead of `address`.
* Bump copyright years.Barry Warsaw2015-01-041-1/+1
|
* Remove huge amounts of now unnecessary file boilerplate.Barry Warsaw2014-12-221-3/+0
|
* Trunk merge.Barry Warsaw2014-12-221-3/+2
|\
| * * Fixed getting non-ASCII filenames from RFC 2231 i18n'd messages. Given byBarry Warsaw2014-12-081-3/+3
| |\ | | | | | | | | | Aurélien Bompard. (LP: #1060951)
| | * Convert unicode instance testing to bytes instance testingAurélien Bompard2014-12-041-2/+2
| | |
| | * Do not auto-convert Message headers to unicodeAurélien Bompard2014-12-021-2/+2
| |/ | | | | | | Fixes: bug #1060951
* | More test repair.Barry Warsaw2014-12-151-1/+1
| |
* | All the REST tests pass.Barry Warsaw2014-12-151-1/+1
| |
* | Use listid instead of (fqdn) listname in the metadata pickle.Barry Warsaw2014-12-151-1/+1
| | | | | | | | | | | | load_external() now always opens in utf-8 mode. More test repair.
* | Checkpointing.Barry Warsaw2014-11-301-4/+4
|/ | | | | | | | | | By using `six` I think I have most of the imports squared away. There's probably still uses of `unicode` built-ins that need fixing. The idea is to first get the test suite running (which it doesn't yet), and then to fix tests. There's a bug in lazr.config which requires us to patch it for now.
* Use print functions consistently through, and update all __future__ imports toBarry Warsaw2014-04-281-1/+1
| | | | | | | | reflect this. Also, mock out sys.stderr on some tests so that their nose2 output is quieter. A few other minor coding style consistencies.
* Several internal improvements:Barry Warsaw2014-01-061-4/+1
| | | | | | | | | | | | | | | | | | | | | | * New events: - ConfirmationNeededEvent is triggered when a pendable requiring confirmation is created. This allows us to define an event handler for this event which sends the user notification. - SubscriptionEvent is triggered when a member is added to a mailing list. This lets us define an event handler which sends the welcome message. * send_welcome_message() now takes a member parameter instead of an address, which lets us directly access the member's delivery mode and user display name (if the member has a user, which it might not in some cases). * Use the list id in the pendable record instead of the list name for robustness (the latter can change but the former is permanent). * Test more registration conditions. * In the bin/runner command line switch handling, default `verbose` to None instead of False. This makes it work better with nose's -E switch (log to stderr). * In call_api(), if a POST, PUT, or PATCH method is used and data is None, encode the empty dictionary; seems like the behavior of urlencode() has changed, so this is safer. * Fix style and pyflakes warnings.
* Bump copyright years.Barry Warsaw2014-01-011-1/+1
|
* Switch to PEP 435 enums from flufl.enums.Barry Warsaw2013-06-181-1/+1
|
* Bump copyright years.Barry Warsaw2013-01-011-1/+1
|
* Expose held subscription/unsubscription requests via the API.Barry Warsaw2012-12-151-3/+2
| | | | | | * hold_subscription(): Don't str(mode) to get a string representation, just mode.name since we know it is a DeliveryMode. This means we don't need to split the value later in handle_subscription().
* Schema change. After discussion at Pycon, we decided to change "real_name" toBarry Warsaw2012-03-151-11/+11
| | | | | | | | | | | "display_name" across the board. * `IMailingList.real_name` -> `IMailingList.display_name` * `IUser.real_name` -> `IUser.display_name` * `IAddress.real_name` -> `IAddress.display_name` * Schema changes: - real_name -> display_name (mailinglist, user, address)
* * Support downloading templates by URI, including mailman:// URIs. This isBarry Warsaw2012-03-031-1/+1
| | | | | | | | | | | | | used in welcome and goodbye messages, and supports both language and mailing list specifications. E.g. mailman:///test@example.com/it/welc.txt * Schema changes: - welcome_msg -> welcome_message_uri - goodbye_msg -> goodbye_message_uri - send_welcome_msg -> send_welcome_message - send_goodbye_msg -> send_goodbye_message * New `ITemplateLoader` utility.
* * Held messages can now be moderated through the REST API. Mailing listBarry Warsaw2012-01-301-9/+9
| | | | | | | | | | | | | | | resources now accept a `held` path component. GETing this returns all held messages for the mailing list. POSTing to a specific request id under this url can dispose of the message using `Action` enums. * `IRequests` interface is removed. Now just use adaptation from `IListRequests` directly (which takes an `IMailingList` object). * `handle_message()` now allows for `Action.hold` which is synonymous with `Action.defer` (since the message is already being held). * `IListRequests.get_request()` now takes an optional `request_type` argument to narrow the search for the given request. - also, print_function is now a standard __future__ import. The template has been updated, but add this to modules as you edit them.
* copybumpBarry Warsaw2012-01-011-1/+1
|
* * Moderating a message with Action.accept now sends the message. (LP: #827697)Barry Warsaw2011-08-221-5/+8
| | | | | | | | | | | Also: * Use utilities.datetime.now() so that moderation related dates are predictable during the test suite. * When a message is accepted, drop it in the pipeline queue. The above bug was caused by the message going in the incoming queue, and then being re-moderated. * Expose mailman.bin.master.Loop in __all__. * Add some helpful debug logging.
* Complete bug 827036 work.Barry Warsaw2011-08-171-0/+13
| | | | | | | | | | | * Add ListCreatingEvent and ListDeletingEvent. These are sent before the operation actually occurs, whereas the previously added ListCreatedEvent and ListDeletedEvent are sent after the operation. Specifically, this is necessary because request database deletion requires the IMailingList object, which is only available before the list is deleted. * Add a handler to clear out the requests database for a mailing list, when the mailing list is about to be deleted.
* Major terminology shift:Barry Warsaw2011-06-011-3/+3
| | | | | | | | | | | | | | | | | * Queue runners are now called just 'Runners' since several of them don't manage queue directories. * Ban the term 'qrunner' too. * The master queue runner watcher should now just be called the 'master' or the 'master runner'. * bin/qrunner -> bin/runner * mailman.qrunner log file -> mailman.runner * master-qrunner.lck -> master.lck * master-qrunner.pid -> master.pid Also: * Remove some obsolete files * Begin the .txt -> .rst renaming
* Reimplement wrap() using modern techniques, and finally get rid of Utils.py!Barry Warsaw2011-03-171-1/+0
|
* Utils.maketext() and Utils.findtext() are gone.Barry Warsaw2011-03-161-19/+21
|
* Happy New Year.Barry Warsaw2011-01-011-1/+1
|
* Happy New Year.Barry Warsaw2010-01-011-1/+1
|
* * Leave a mailing list via the REST API.Barry Warsaw2009-12-281-3/+3
| | | | | | * delete_member(): If the address is not associated with a member, raise NotAMemberError. * NotAMemberError -> interfaces/member.py
* * Refactor the language manager off of the config object and into a utility.Barry Warsaw2009-12-101-2/+3
| | | | | | | | * Fix a few small typos in exception handlers. * Move the initialization of the Zope Component Architecture into the first initialization step. The only reason we couldn't do that previously was because the domain object referenced the config, causing a circularity problem. Refactor the Domain implementation to avoid that.
* Factor out most of the i18n subsystem and convert to using the flufl.i18nBarry Warsaw2009-11-151-4/+3
| | | | package.
* As before, replace config.db.requests and config.db.pendings with utilities.Barry Warsaw2009-08-261-7/+7
|
* Replace the message_store instance on the database with an IMessageStoreBarry Warsaw2009-08-261-4/+7
| | | | utility.
* Wow. Put domains into the database.Barry Warsaw2009-07-161-2/+3
| | | | | | | | Add an IDomainManager and a global domain manager which can be gotten by adapting the global config object. Add an IDomainCollection interface for exposing the domain manager onto the API.
* More lint picking.Barry Warsaw2009-07-041-1/+2
| | | | Fix a documentation link.