summaryrefslogtreecommitdiff
path: root/src/mailman/model/roster.py
Commit message (Collapse)AuthorAgeFilesLines
* Bump copyright years.Barry Warsaw2017-01-041-1/+1
|
* Use `atpublic` for @public instead of internal copy.Barry Warsaw2016-11-291-1/+1
|
* Clean up the model and languages directories.Barry Warsaw2016-03-251-25/+15
|
* Fix membership query for preferred addresses.Barry Warsaw2016-02-061-2/+3
| | | | | | | When multiple users are subscribed to a mailing list via their preferred address, too many results are returned from a membership query, resulting in an assertion error. Reported by Darrell Kresge. (Closes: #190)
* Several optimizations:Barry Warsaw2016-01-111-37/+12
| | | | | | | | | | | | * 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-021-1/+1
|
* The ``mailman members`` command can now be used to display members based onBarry Warsaw2015-12-221-1/+1
| | | | | subscription roles. Also, the positional "list" argument can now accept list names or list-ids.
* Optimize the roster SQL queryAurélien Bompard2015-11-221-3/+5
| | | | | | Measured improvement: about 100x faster. (!) Reformatting.
* Merge the member query fix branch.Barry Warsaw2015-04-141-10/+46
|\
| * Added IMember.subscriber to definitively return how a member is subscribed toBarry Warsaw2015-04-141-11/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | the mailing list (via preferred address/user or explicit address). IMember.get_member() is defined to return the explicit address when members are subscribed in both ways. IMember.get_memberships() returns a sequence of length 0, 1, or 2 containing all the member records associated with the email address. Fixed the AbstractMemberRoster methods query to properly return subscriptions via the user's preferred address and via an explicit address.
* | Subscription workflow checkpointing.Barry Warsaw2015-04-091-5/+7
| | | | | | | | | | | | | | | | | | | | * TO DO: - hook up sending of confirmation - processing confirmations and continuing workflow - get tokens for saving workflows - integrate with RequestRecord - integrate with hold_subscription - after getting moderator approval, continue workflow
* | Resurrect Barry's subpolicy branch (lp:~barry/mailman/subpolicy)Aurélien Bompard2015-03-201-3/+1
|/
* Bump copyright years.Barry Warsaw2015-01-041-1/+1
|
* Remove huge amounts of now unnecessary file boilerplate.Barry Warsaw2014-12-221-6/+2
|
* DatabaseBarry Warsaw2014-11-011-29/+22
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -------- * The ORM layer, previously implemented with Storm, has been replaced by SQLAlchemy, thanks to the fantastic work by Abhilash Raj and Aurélien Bompard. Alembic is now used for all database schema migrations. * The new logger `mailman.database` logs any errors at the database layer. API --- * Several changes to the internal API: - `IListManager.mailing_lists` is guaranteed to be sorted in List-ID order. - `IDomains.mailing_lists` is guaranteed to be sorted in List-ID order. - Iteration over domains via the `IDomainManager` is guaranteed to be sorted by `IDomain.mail_host` order. - `ITemporaryDatabase` interface and all implementations are removed.
| * Clean up pass.Barry Warsaw2014-09-221-2/+2
| |
| * fix all tests in mailman.model.testsAbhilash Raj2014-09-131-6/+5
| |
| * modify all storm queries to work with SAAbhilash Raj2014-09-121-22/+16
| |
| * * change declarative_base class to use ModelMeta classAbhilash Raj2014-09-061-1/+1
|/ | | | * update some queries to match SA style
* Bump copyright years.Barry Warsaw2014-01-011-1/+1
|
* Bump copyright years.Barry Warsaw2013-01-011-1/+1
|
* * The link between members and the mailing lists they are subscribed to, isBarry Warsaw2012-09-041-7/+7
| | | | | | | | | | | | | | | now via the RFC 2369 `list_id` instead of the fqdn listname (i.e. posting address). This is because while the posting address can change if the mailing list is moved to a new server, the list id is fixed. (LP: #1024509) + IListManager.get_by_list_id() added. + IListManager.list_ids added. + IMailingList.list_id added. + Several internal APIs that accepted fqdn list names now require list ids, e.g. ISubscriptionService.join() and .find_members(). + IMember.list_id attribute added; .mailing_list is now an alias that retrieves and returns the IMailingList. - list_id added (LP: #1024509)
* General code cleanup.Barry Warsaw2012-04-251-5/+3
| | | | | | | | - Add explicit dependency on zope.event in setup.py. - Use Python 3 compatible syntax for specifying that a class implements an interface, i.e. the @implementer class decorator. - print_function futures. - Whitespace normalization.
* - Module modernatizations (print function).Barry Warsaw2012-04-221-20/+26
| | | | - Convert direct use of config.db global to use the @dbconnection decorator.
* * Add property `IRoster.member_count`.Barry Warsaw2012-03-151-27/+42
| | | | | Also, change the implementation of mailing list REST resource's member_count to use the more efficient implementation of IRoster.member_count.
* copybumpBarry Warsaw2012-01-011-1/+1
|
* Add some tests to ensure that the correct number of members are returned whenBarry Warsaw2011-04-171-3/+4
| | | | users are subscribed with their preferred addresses.
* Happy New Year.Barry Warsaw2011-01-011-1/+1
|
* Because it was just to damn confusing, rename IAddress.address toBarry Warsaw2011-01-011-2/+2
| | | | | | IAddress.email and IAddress.original_address to IAddress.original_email. From now on we'll use "address" to talk about the IAddress object and "email" to talk about the textual email address.
* Fairly significant change to the way member and nonmember moderation occurs.Barry Warsaw2010-12-291-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | Now, nonmembers are represented by a separate roster of IMembers, the latter which has grown a `moderation_action` enum. When that action is `defer`, then the normal processing rules apply. Anything else and the `moderation` chain is jumped to for a shortcut to moderation (which may include immediate acceptance). TODO: handle unregistered nonmembers. Details: * The member-moderation rule is renamed to just moderation, and handles both members and nonmembers (though the latter must currently be registered). * The moderation rule is moved up in the builtin chain. It is now checked after `approved`, `emergency`, and `loop`, but before the normal moderation checks. This means that nonmember postings will be (by default) held much earlier. * IMember.is_moderated is removed. * IMember.moderation_action is added. * IMailingList.default_member_moderation is removed. * IMailingList.default_member_action and IMailingList.default_nonmember_action are added. * MemberRole.nonmember is added.
* Fix the obvious errors identified by pyflakes. Skip false positives (mostlyBarry Warsaw2010-10-081-2/+1
| | | | | due to _() interpolation) and a few other problems that did not have immediately obvious fixes.
* Happy New Year.Barry Warsaw2010-01-011-1/+1
|
* * Add REST interface for joining a mailing list.Barry Warsaw2009-12-281-0/+13
| | | | | | * add_member() now returns the newly created IMember. * Reorganized several exceptions and exposed them to the REST API. * Added NoSuchListError.
* database/model reorganization. Model classes go in mailman.model. StockBarry Warsaw2009-10-101-0/+271
database support goes in mailman.database. Move stuff out of mailman/database/__init__.py.