Merge lp:~jcsackett/launchpad/membership-status-matters-676494 into lp:launchpad
Status: | Merged |
---|---|
Approved by: | j.c.sackett |
Approved revision: | no longer in the source branch. |
Merged at revision: | 12047 |
Proposed branch: | lp:~jcsackett/launchpad/membership-status-matters-676494 |
Merge into: | lp:launchpad |
Diff against target: |
130 lines (+52/-7) 4 files modified
lib/lp/registry/interfaces/teammembership.py (+4/-0) lib/lp/registry/model/person.py (+7/-4) lib/lp/registry/model/teammembership.py (+1/-3) lib/lp/registry/tests/test_team.py (+40/-0) |
To merge this branch: | bzr merge lp:~jcsackett/launchpad/membership-status-matters-676494 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Brad Crittenden (community) | code | Approve | |
Review via email: mp+43303@code.launchpad.net |
Commit message
[r=bac][ui=none][bug=676494] Fixes a bad filter in deactivateAllMe
Description of the change
Summary
=======
In merges, there was an execution path that didn't fully clean up TeamParticipation entries for indirect memberships. A branch was landed to deal with this, but it filtered out TeamParticipation entries corresponding to any TeamMembership entry. To be correct, it should only avoid deleting TeamParticipation entries that correspond to an ACTIVE TeamMembership entry.
This branch modifies the cleanup query to filter only on ACTIVE states.
Preimplementation Talks
=======
Long debate and exploration with the Registry Team, esp Curtis Hovey.
Implementation
==============
The query to cleanup indirect membership TeamParticipation entries was modified to only avoid deleting entries corresponding to TeamMemberships that are active (e.g. status of APPROVED or ADMIN)
Tests
=====
bin/test -vvct MembershipManag
Lint
====
make lint output:
= Launchpad lint =
Checking for conflicts and issues in changed files.
Linting changed files:
lib/lp/
lib/lp/
Aside from moving ACTIVE_STATES to in the teammembership interface, as discussed on IRC, this looks good. Thanks.