You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[People · Phase 2] End a socio's status, automatic lapse and account deletion #124
How a socio's status ends: by hand (resigned, expelled, deceased, other) or automatically when the fee is unpaid after 31 December. Ending removes the account from the Soci group, so Auth drops the Socio role, and lists the account under Deletion pending until someone deletes it. Phase 2: PoliNetworkOrg/admin#144. Design: docs/people/soci.md (PoliNetworkOrg/admin#154). Builds on #122 and #123.
Rules
Ending: sets ended_on, end_reason and end_note, removes the user from Soci (Graph), and sets the account to pending_deletion. Auth drops Socio within about a minute.
Automatic lapse: a daily job from 1 January, only with SOCI_AUTO_LAPSE=true (default off until the register is complete).
It ends every active socio whose fee for the year that just closed is still due, with reason lapsed and ended_on = 31 December.
An upload waiting for review protects the socio until it's reviewed; a rejection after the deadline lapses them at the next run.
It sends a lapse email to the mailbox.
Restore: for mistakes only, with a reason. It is possible while the account still exists: the user is added back to Soci and the end is cleared.
Delete account: one user at a time. It deletes the Microsoft 365 user (licences go with it). The record keeps the object ID, mailbox and deletion date, and the account becomes deleted.
Procedures
Procedure
Policy
members.end, members.restore
admin:access + soci:write
accounts.pendingDeletion, lapse.preview (who would lapse at the next run)
admin:access + soci:read
accounts.delete (one ID)
admin:access + soci:delete
Done when
Procedures, the job, the mock directory's group removal / re-add / deletion and the lapse template exist.
Tests cover:
the switch off means no lapse;
uploaded fees are protected;
a Graph failure leaves the socio active, logs the error and retries the next day;
restore re-adds to Soci;
delete refuses active soci and IDs that aren't pending deletion.
#104 - refactor(people)!: remove Soci, fees, receipts, census and record matching [closed] #96 - fix(azure)!: remove group membership writes [merged]
📝 Issue Planner
Check the box below or use the @coderabbitai plan command to generate an implementation plan and prompts that you can use with your favorite coding assistant.
Create Plan
🧪 Issue enrichment is currently in open beta.
You can configure auto-planning by selecting labels in the issue_enrichment configuration.
To disable automatic issue enrichment, add the following to your .coderabbit.yaml:
issue_enrichment:
auto_enrich:
enabled: false
💬 Have feedback or questions? Drop into our discord!
Activity
coderabbitai commentedon Nov 9, 2026
🔗 Related PRs
#104 - refactor(people)!: remove Soci, fees, receipts, census and record matching [closed]
#96 - fix(azure)!: remove group membership writes [merged]
📝 Issue Planner
Check the box below or use the
@coderabbitai plancommand to generate an implementation plan and prompts that you can use with your favorite coding assistant.🧪 Issue enrichment is currently in open beta.
You can configure auto-planning by selecting labels in the issue_enrichment configuration.
To disable automatic issue enrichment, add the following to your
.coderabbit.yaml:💬 Have feedback or questions? Drop into our discord!