summaryrefslogtreecommitdiff
path: root/src/mailman/core
Commit message (Collapse)AuthorAgeFilesLines
* Fix coverage, deprecate, but run non-plugin (post|pre)_hooks.pluggable-componentsJ08nY2017-08-071-12/+16
|
* Don't fail when plugins pre_hook or post_hook fails.J08nY2017-08-071-10/+33
| | | | | | | | - Catches all exceptions raised when running a plugins (pre|post) _hooks. If its pre_hook raises an exception, the plugin is disabled and removed, so its post_hook will not be run and its components will not be loaded. If its post_hook raises an exception we just continue and hope for the best.
* Make config.plugin_configs yield a dict with plugin names.J08nY2017-08-071-2/+1
| | | | - Allows to better loop over pluging configs and their names.
* Add per-plugin hooks, add docs about plugins.J08nY2017-08-072-9/+62
| | | | | | | | | | | | | | | - Removes pre_hook, post_hook and ext_dir. With the latter being unused. Warns on startup if the hooks are present in config. - Adds IPlugin interface with pre_hook and post_hook methods. - Adds 'class' config parameter to plugins, which can be set to a class implementing the IPlugin interface, it will be initialized once on Mailman's startup, then before the DB setup the pre_hook will be run, after DB and other components the post_hook will be run. Plugin instances are stored in the config.plugins dict, with keys being their configuration section names.
* Add pluggable components.J08nY2017-08-073-8/+7
| | | | | | | | | | | | | | | | | - Adds the notion of a 'plugin'. - A plugin has a package path and a flag specifying whether it's enabled or not. - Adds a find_pluggable_components function similar to the find_components one. This one dynamically searches not only the mailman package but all of plugins. - e.g. find_pluggable_components('rules', IRule) finds all IRule components in mailman.rules but also in example_plugin.rules for plugin names example_plugin. - Uses the find_pluggable_components function in place of find_components when searching for Rules, Handlers, Chains, EmailCommands, and Styles.
* Rename metadata key for clarityBarry Warsaw2017-08-043-8/+63
|
* Convert to click for CLI optionsBarry Warsaw2017-07-221-3/+5
|
* Added a rule to discard messages with no valid sender address.Mark Sapiro2017-06-301-4/+5
|
* Move pipelines to their own package, instantiate them dynamically.pipelines-dynamical-instantiationJ08nY2017-06-171-79/+2
|
* Provide a better way to avoid instantiating some componentsBarry Warsaw2017-06-173-35/+6
|
* Enhance Switchboard.finish() to look for .pck if no .bak.Mark Sapiro2017-04-222-0/+27
|
* Fix signal handler exception.Barry Warsaw2017-02-011-14/+15
|
* Handle PEP 475 fallout.Barry Warsaw2017-01-281-2/+13
| | | | | | | | | | | | | | | Closes #255 As of Python 3.5, PEP 475 gets in our way. Runners with long time.sleep()'s in their _snooze() method (e.g. the retry runner) will have their system call implemented time.sleep() automatically retried at the C layer. The only reliable way to prevent this is to raise an exception in the signal handler. The standard run() method automatically suppresses this exception, meaning, it's caught and ignored, but effectively breaks the run() loop, which is just what we want. The lmtp and rest runners implement their own run loops, so they also have to handle this exception, by ignoring it.
* Bump copyright years.Barry Warsaw2017-01-0414-14/+14
|
* Simplified the various list settings and remamed several things.Mark Sapiro2016-12-261-2/+2
|
* Merged from master.Mark Sapiro2016-12-0911-11/+12
|\
| * More fixes & flufl.testing.Barry Warsaw2016-11-291-1/+2
| |
| * Use `atpublic` for @public instead of internal copy.Barry Warsaw2016-11-2911-11/+11
| |
* | Merge branch 'dmarc' of gitlab.com:msapiro/mailman into dmarcMark Sapiro2016-11-262-3/+5
|\ \ | |/ |/|
| * Fixed some doctests for the addition of the dmarc-moderation rule.Mark Sapiro2016-11-011-3/+4
| |
| * DMARC mitigations, part 1a.Mark Sapiro2016-10-311-0/+1
| |
* | Replace smtpd with aiosmtpd.Barry Warsaw2016-11-241-0/+4
|/
* Prevent posting from banned addressesAurélien Bompard2016-10-271-3/+5
| | | | Fixes #283
* Reorganize the documentation for better accesibilityAbhilash Raj2016-08-211-0/+9
|
* Rebase mailman/mailman!180 and cleanup # noqaBarry Warsaw2016-07-281-2/+3
|
* New template system. Closes #249Barry Warsaw2016-07-162-2/+2
| | | | | The new template system is introduced for API 3.1. See ``src/mailman/rest/docs/templates.rst`` for details.
* Better handling of the REST API plumbing.Barry Warsaw2016-06-281-0/+2
| | | | | | | | | * Add a version_info field which is a better way to do ordered comparisions of the API version. * All subresources now get their .api attribute set automatically, if they are passed back through the ObjectRouter. No more fiddling with context['api'] (unless of course, they don't make a roundtrip through the main ObjectRouter loop.
* Use contextlib.suppress() where appropriate.Barry Warsaw2016-04-301-5/+3
|
* flake8 clean.Barry Warsaw2016-04-061-1/+1
|
* public() takes keyword arguments.Barry Warsaw2016-04-044-9/+6
|
* Tweak the import rules checker.Barry Warsaw2016-03-271-1/+1
| | | | Fix the last few violations of the import rules.
* Reorder the @public definition.Barry Warsaw2016-03-251-8/+4
| | | | This allows us to import it in more places without threat of import errors.
* Clean up the core directory.Barry Warsaw2016-03-2415-332/+80
| | | | | | | mailman/core/errors.py is gone now. We had a duplicate base exception which now always comes from mailman/interfaces/errors.py. Obsolete/unused exceptions are remove. The other exceptions are moved to better locations.
* Super duper.Barry Warsaw2016-01-261-25/+0
| | | | | * Python 3-ify super() calls. * Remove a bunch of obsolete exception classes.
* Make creating Link objects a more convenient.Barry Warsaw2016-01-252-6/+2
| | | | | | Link.__init__() can now take an IRule or the string naming a rule, which will be looked up in config.rules. Similarly, it can take an IChain or the name of a chain.
* Just a little more UUID conversion convenience.Barry Warsaw2016-01-131-4/+8
|
* Refactor API differences into a separate class.Barry Warsaw2016-01-131-0/+82
| | | | | | | | | | | We now have an IAPI interface which defines methods to convert to/from UUIDs to their REST representations, and to calculate the API-homed full URL path to a resource. Add implementations API30 and API31 to handle the two different implementations so far. This also simplifies the various path_to() calls. Also: Add support for diff_cover to tox.ini to check that all differences against the master branch have full test coverage.
* Several optimizations:Barry Warsaw2016-01-111-2/+1
| | | | | | | | | | | | * Use `yield from` wherever appropriate. * Use SA's .one_or_none() where appropriate. - Fix a bug in MailingList.pass_extensions. - Use ValueError in other places for consistency. - Remove unreached/nonsense code. - Simplify the SubscriptionService.find_member() and .find_members() implementations. - Boost coverage.
* Happy New Year.Barry Warsaw2016-01-0214-14/+14
|
* Digests improvements:Barry Warsaw2015-12-191-1/+1
| | | | | | | * digestable -> digests_enabled * nondigestable: removed * Exposed digests_enabled, digest_send_periodic, digest_volume_frequency in REST.
* Reorder the default-posting-chain to avoid spam.Aurélien Bompard2015-11-211-2/+2
| | | | | | Fixes: #163 Adapt unit tests.
* A few minor cleanups.Barry Warsaw2015-09-131-11/+10
|
* Don't decorate the archive, digest or usenet copiesAurélien Bompard2015-09-122-2/+40
|
* Decorate bulk emails by defaultAurélien Bompard2015-09-081-0/+1
|
* For now, treat `DeliveryMode.summary_digests` the same as `.mime_digests`.Barry Warsaw2015-09-061-2/+9
| | | | | (Closes #141). Also, don't enqueue a particular digest if there are no recipients for that digest.
* * Messages now include a `Message-ID-Hash` as the replacement forBarry Warsaw2015-06-141-3/+6
| | | | | | `X-Message-ID-Hash` although the latter is still included for backward compatibility. Also be sure that all places which add the header use the same algorithm.
* * A handful of unused legacy exceptions have been removed. The redundantBarry Warsaw2015-05-241-19/+1
| | | | `MailmanException` has been removed; use `MailmanError` everywhere.
* Implement reasons for why a message is being held for moderator approval.Barry Warsaw2015-05-111-54/+5
| | | | | | | Given by Aurélien Bompard, tweaked by Barry Warsaw. Remove the inaccurate confirmation url and admindb urls from the substitution dictionaries for postauth.txt and posthold.txt, and the templates.
* Add a test to prove that LP: #1165589 doesn't affect Mailman 3.Barry Warsaw2015-05-041-0/+58
|
* Clean up some templates; given by raj-abhilash1Barry Warsaw2015-04-161-7/+4
|\