| H1: `rotateAway` is refused "a rotation is still running", says so, and gives up | worse: it is not refused. `proposeRefresh` hands a running rotation back, so `rotateAway` marked the change done **silently**, and the removed member got a share of the next generation with nothing said. Phase 4 checks the rotation it is handed and says so when it still deals to them |
| H2: the new id is left `STALE` at `g+1` | worse: the rotation **fails**. The binding grows the base generation's table under a rotation dealt against the old one, and round 2's own check refuses the result ("what was dealt does not match the commitments") on every device |
| Phase 1: pin H5 as "the request is deleted" | the governance harness's room is at its admin floor, so the request was used up by the floor whatever the rotation did. Pinned as used up, then rewritten in Phase 3 to show it kept through the rotation and taken up after |
| Phase 2: the Shares section's two new held reasons land in Phase 4 | in Phase 2, since the `when` over `RotationHold` is exhaustive |
| Phase 2: `AdminChangeInFlight` counts the proposer's rows "signed or published and not yet applied" | `SIGNING` or `PUBLISHED`, and the group not yet past the proposal's epoch, which is how `rotationsOwed` tells a change that landed unwatched. A statement session this device declined does not hold it, as for key states |
| Phase 2: `Enrolling` holds until the enrollment completes or fails | also not for a bound member the live group does not name an admin. A promotion whose commit went stale leaves a signed binding nobody will enroll, which would otherwise hold every rotation for good |
| (not in the plan) | the share rituals' test devices hold no MLS group, so nothing there can read an admin policy. `RoomAdmins` reads it off the live group, with an `override` the tests set, as `ExperimentalFeatures.shareRefreshOverride` stands in for the build. As with member-admin-promotion, no test runs a whole removal with real MLS and real FROST together: the governed-room tests have no FROST key, and the ritual tests stand the policy in |
| Phase 3: a test that the freeze also holds while the key state is unsigned | in the ritual harness (`an admin change waits on a rotation until its key state is signed`), where a real rotation produces one; the governance harness's seeded key has no generations |
| Phase 3: **See the rotation** goes to the group's Shares section | back, to the group's screen beneath, where the Shares section is |
| Phase 3: *"Waiting on Carol since yesterday"* | the names only, while the rotation is dealing. The card in the Shares section has the time |
| A12's test goes through `GovernanceManager.propose` | through `ShareRefreshManager.owedRotationRefusal` on a real six-holder roster with a stale member. The governance harness cannot make a member stale |
| Phase 5: `takePartIfNothingNew` called on arrival, after a commit that changes admins, and in the sweep | once, at `advance`'s one gate, which arrival, a replay and the sweep all reach. The commit-time trigger was not built: a rotation travels as an inner event at the epoch after the commit it follows, so no device reads it before applying that commit, and the sweep covers a session an older build left asking |
| Phase 5: the transcript line in place of the approval-needed one | with a type of its own, `TYPE_SHARE_REFRESH_TOOK_PART`, in both share-refresh sets so it renders as a notice |
| Phase 6: `offer` proposes the rotation | `offer` takes the account key, which `DatabaseChatRepository.promoteMember` passes through `MarmotOutboundDao.promote`. Without it, the refusal is as before |
| Phase 6: two admins offering at once start one rotation, and both offers go ahead after it | the plan contradicted itself: its own freeze refuses the second offer while the first one's rotation runs, and that is what the build does. Two devices offering in the same moment each propose a rotation; the two refuse each other on arrival, as any crossing rotations do, and both offers end out loud once nothing is running |
| Phase 6: the whole first promotion in one test | in parts: the offer starting its rotation, the wait, and the abandon in the governance harness, and the rotation running unasked in the ritual harness (A2). The same harness gap as above |
| Phase 7: the member row's line comes from member-row-actions Phase 5's pending lines | that phase did not leave a line on the row to extend. **Holds a share** reads **Share being rotated away** instead while a running rotation takes it, from `SharesSummary.Running.takingAway` |
| (not in the plan) | two full `jvmTest` runs each had one identity test time out at 5 seconds (`MultipleProfilesRoundTripJvmTest`, then `IdentitySwitchJvmTest`). Both pass alone, repeatedly, neither starts the governance follow-through, and a third full run passed whole. Load, not this work; not investigated |
| A4: never retire a founding member `FoundingAdmins.check` reports `Missing` | built, then taken out when this branch met [remove-founding-admins-card.md](./remove-founding-admins-card.md) on `giza`, which deleted the check: it cannot tell a founder a buggy creator left out from one the group demoted, and every founder is an admin when the room is made (robust-group-admins). A governed room's live policy is the whole answer. The two tests of the guard went with it |
| (not in the plan) | this worktree's build needed its submodules initialised, from the main checkout's copies, and their `local.properties` copied in |
**Not done:** the emulator session in Phase 8. Nothing here has run on a device: not the
held menu, not the first promotion's rotation, not a removal on three phones.
### Removing an admin (Remove as admin, Remove from group, or Step down)
| # | step | who | asked? |
|---|---|---|---|
| 1 | propose the change: `MarmotOutboundDao.demote` / `removeMember` → `GovernanceManager.propose`, with `thenRotateWithout` set when the member holds a live share | an admin (for a step-down, `AdminGovernance.stepDownProposer`) | the button, behind a dialog |
| 2 | sign the governance statement (30370) | `t` holders | **yes, the decision.** Stays asked |
| 3 | publish, apply the commit everywhere | proposer, then every device | no |
| 4 | start the rotation without the member: `GovernanceFollowThrough.rotateAway` → `ShareRefreshManager.proposeWithout` | proposer | no (proposing is the proposer's approval) |
| 5 | take part in the rotation (`ShareRefreshApprovalStep.DEAL`) | **every other remaining holder** | **yes: the ask this plan removes** |
| 6 | rounds, certificate, key state at `g+1`, wipe `g` | every device | no (rotate-shares-single-approval) |
So a removal in a 3-of-5 room asks three people to sign it, and then asks all four
remaining holders, including those three, whether they agree to the rotation the
signature already required. A holder who never opens the Shares section holds the
rotation open indefinitely. Meanwhile the demoted member's share still counts toward `t`
(D10), and their row reads **Holds a share** without **Admin**.
### Adding an admin (Make admin)
Promotion is an enrollment, not a rotation (member-admin-promotion Phase 8). After the
target accepts, the group signs one batch (the statement and the key state binding id `n`),
the handover goes out, and `t` helpers enroll the new id without being asked. The only
rotation in this flow is the one that has to come first:
"Rotate the group's shares once before adding an admin: the key's first generation is its ceremony's, and has no room for a new member"
}
```
Every keyed room starts at generation 0, so the **first** promotion in every room fails
with this message. The admin then has to go to the Shares section, rotate, wait until
every holder has tapped **Approve**, wait until the key state is signed, and come back to
press **Make admin** again.
### What nothing prevents today
Admin changes and rotations both act on the same thing, the roster of who holds which id
at which generation. Nothing stops them from overlapping:
| | overlap | what goes wrong |
|---|---|---|
| H1 | an admin is demoted while a rotation `g → g+1` is running | `rotateAway` is refused ("a rotation is still running"), says so in the room, and gives up. The running rotation was proposed before the demotion, so **the demoted member is one of its recipients and receives a fresh share at `g+1`.** D10's window stays open until somebody notices and rotates again |
| H2 | a promotion's key state is signed while a rotation is running | `enrollNewId` adds id `n` at `g`, as `STALE`. The rotation's proposal was fixed against the roster before `n` existed, so id `n` is neither a recipient nor withheld. At `g+1` the new admin is stale, and needs a repair instead of the enrollment they were promised |
| H3 | a rotation is started while an enrollment is owed or running | the new id is `STALE` at `g` until enrolled, so `plan` withholds it as stale. Same outcome as H2, reached from the other side |
| H4 | a governance statement is being signed at `g` when the rotation's key state at `g+1` is signed | `FrostSigningManager.failRotated` fails every open session below `g+1`, the statement included. Its signers' approvals are lost, and the change has to be proposed again |
| H5 | a step-down request or an accepted offer arrives during a rotation | `followStepDowns` and the accepted-offer loop each run once, are refused, and **drop** the request (`deleteById`, `failedOffers`). The person who asked has to ask again |
H1 is the serious one. It is a removed admin who can still help sign, and the room shows
nothing different from the case where the rotation succeeded.
---
## Why the rotation's ask is not a decision
`DEAL` asks one question: *do you agree to take part, with these members withheld?*
(rotate-shares-single-approval R1). Withholding someone takes their signing power away, so
the withheld list is the whole of the decision. Everything else about a rotation is
arithmetic the device checks for itself.
The withheld list a rotation after an admin change carries has two parts, and the group
has already decided both:
- **Retired:** the member the group just removed as admin. In a governed room the admin
policy changes only through a commit the group's threshold signature carries
(member-admin-promotion R2, `GovernanceGate`). If the live group no longer names them an
admin, `t` holders already signed that, and R1 says a non-admin holds no share.
- **Stale:** members who already missed a rotation. `plan` withholds them again as what
they were (`ShareRefreshManager.kt:124`). Withholding them takes nothing new: they cannot
sign at `g` now and will not at `g+1`. A repair, not a rotation, brings them back.
A device can check both against state it already trusts, the live MLS group and its own
roster at the base generation. If both hold, a person has nothing to add. If either fails,
someone is being withheld whom the group has not decided about, and the owner is asked as
they are today.
The same rule covers the rotation before a first promotion, which withholds no one new at
| A1 | How does a recipient know a rotation follows an admin change? | **It doesn't need to. It checks that the rotation withholds nobody new** (the rule above), from the live group and its roster. No new tag, nothing to look up, and nothing a proposer can claim that the device does not check | A `frost_follows` tag naming the signed statement (30370) the rotation follows. The recipient looks up the statement and checks that it removes exactly the retired ids. The coupling is narrower, but it adds a wire change, and the statement has to have been stored and found, which a device that caught up from a later epoch may not have done |
| A2 | Does A1 also take part, unasked, in a **manual** rotation that withholds nobody new (the Shares section's **Rotate shares** with only stale members left out)? | **Yes.** It follows from A1. That rotation takes nobody's signing power, which is the only thing `DEAL` ever decided. Abandon stays for a member who objects to the rotation itself | Only with A1's alternative tag. A manual rotation then keeps its ask, and the generation-0 rotation before a promotion (A7) needs a tag of its own |
| A3 | Should every rotation withhold, as retired, each live holder the group no longer names an admin? | **Yes.**`plan` adds them, so R1 holds whichever rotation runs first. This closes H1's race from the proposer's side: a manual rotation that runs between the commit and `rotateAway` takes the demoted share away too | `rotateAway` stays the only rotation that retires anyone, and the race in H1 has to be closed by the freeze alone |
| A4 | Where does A1 and A3 apply? | **Governed keyed rooms only, and never to a founding member that `FoundingAdmins.check` reports `Missing`.** The epoch-0 admin list is the creator's and is not signed. A founder left out of it by a buggy creator is not a demoted admin, and their share is not to be taken away silently | — |
| A5 | What counts as "a rotation pending" for the freeze? | **`ShareRefreshManager.rotationHold != null`**: a refresh running, the new generation's key state not yet signed, or this device behind. It is the same rule the **Rotate shares** button already follows, and it ends at the same moment the old shares are wiped | Only a running refresh. H4 stays open: a statement being signed when the key state lands is failed by `failRotated` |
| A6 | Which changes does the freeze stop? | **Every change to who is an admin, and every removal of a member who holds a live share.** Promotion offers, accepting an offer, proposing a promotion, demotion, removal of a holder, and step-down. **Not** inviting or removing a member who holds no share. Those do not touch the roster, and the worst H4 does to them is a signing session failed out loud and safe to repeat | Freeze every governed commit. Simpler to state, but a rotation stalled on an offline holder would then stop the room from inviting anyone until someone abandons it |
| A7 | What does the freeze do to a request that arrives during it, such as a step-down or an accepted offer? | **It waits.** The request is kept and taken up by the follow-through's next pass after the hold clears. Today's failure path (drop and announce) stays for real refusals, such as the floor | Refused and dropped, as H5. The requester asks again |
| A8 | Does an enrollment hold rotation? | **Yes, while one is owed or running**: an id the signed key state binds at the active generation, `STALE` here, and with no enrollment for it that has failed. A failed enrollment releases the hold, since a later repair brings that id back at any generation | No, as rotation-waits-for-key-state R3 decided for repairs. H2 and H3 stay open |
| A9 | A promotion at generation 0? | **The offer starts the rotation, and the promotion waits for it.****Make admin** at generation 0 says, in its dialog, that the shares are rotated first. The offer goes out at once. Its proposal (step 3) waits in the follow-through until the generation-1 key state is signed. Nobody presses anything twice | (b) The refusal stays and says what to do, as today. (c) Every keyed room rotates once at birth, from `CeremonyFollowThrough`, so generation 0 is never seen by an admin. That costs a rotation, which needs every member online, for every room, including the many that never promote |
| A10 | A timer? | **No**, as in both earlier notes. The freeze raises the cost of a stalled rotation, so the explanation screen for a frozen action names who the rotation waits on and links to the Shares section's running card, where **Abandon** is | — |
| A11 | Wire or schema? | **Neither.** No kind or tag (A1). No column: `dealApprovedAt` records the unasked approval as it records the asked one, and the transcript line says which | — |
| A12 | Is a demotion or removal of a holder refused when the rotation it owes would be? | **Yes, before anyone signs.** The admin floor counts admins; the rotation's `refusal` counts recipients against every id not yet retired, stale ones included. After an abandoned rotation the two can disagree (see [After an abandon](#after-an-abandon)), and a demotion that lands with a rotation nobody can run leaves a non-admin holding a live share with no way to take it away but a repair first | The change lands, `rotateAway` says the rotation was refused, and the room repairs before it can rotate |
**Decided 2026-11-20: all twelve as recommended.** A12 was added after the first draft,
from a review of what an abandon leaves behind.
### After an abandon
Abandoning a rotation releases the freeze at once: `abandon` fails the session everywhere,
nothing is running, and the active generation is still the one the group signed, so
`rotationHold` and `adminChangeHold` are both null. What it leaves is a live share held by
someone who is no longer an admin, D10's window still open, and a **Rotate shares** offer
in the Shares section. Nothing restarts the rotation by itself (A10).
Under A3 the next rotation, whoever starts it and for whatever reason, retires that share
too, so an abandon delays the cleanup rather than losing it. But retirements owed by
abandoned rotations add up. Six holders at `t = 3`, Carol stale, Alice demoted and her
rotation abandoned: demoting Bob keeps four admins, above the floor, yet the rotation it
owes withholds Alice, Bob and Carol, three of six, which is not a majority. A12 refuses
Bob's demotion before it is signed, with words that say what to fix: rotate first, or
bring Carol back.
---
## Phase 1: pin today's behaviour
**Half a day. Before changing anything.**
The overlaps are bugs and the asks are by design, so both need a test that states them
before either changes. Every test below fails, or is inverted, in a later phase that names
it.
In `GovernanceGateJvmTest` and `ShareRefreshRitualJvmTest`, on their existing fixtures:
- **the ask, counted.** A governed 2-of-4 room with real FROST. Demote one admin through
`GovernanceManager.propose` with `thenRotateWithout`, sign with `approveSigning`, land it,
and run `GovernanceFollowThrough.pass` on the proposer. Then `pump` without `approveAll`.
Every remaining holder but the proposer is at `pendingApproval == DEAL`, and nobody has
reached `g+1`. `asksOf` (from rotate-shares-single-approval Phase 1) is 1 for each.
*Phase 5 inverts this.*
- **H1, pinned.** Start a rotation, then demote and land the demotion before the rotation
completes. `rotateAway` writes `TYPE_CHANGE_NOT_APPLIED`, and at `g+1` the demoted member
holds a `LIVE` share. *Phases 3 and 4 make this impossible, and the test then asserts
that the demotion was refused while the rotation ran.*
- **H2, pinned**, on `a new member is enrolled at the next id`'s fixture: sign a promotion's
key state while a rotation runs. At `g+1` the new id is `STALE`.
- **H4, pinned.** A statement opened for signing at `g`, then the rotation's key state
signed. The statement's session is `FAILED` with `failRotated`'s reason.
- **H5, pinned.** A step-down request taken up while a rotation runs is deleted.
- **The first promotion, pinned.** `PromotionManager.offer` at generation 0 throws the
generation message. *Phase 6 inverts this.*
**Done when** each pinned test passes against today's code and names the phase that
changes it.
---
## Phase 2: one rule for what waits on what
**Half a day.**
Both directions read one function each, from one file, so the menu, the Shares section,
the managers and the follow-through cannot disagree. This is the same discipline as
`rotationHold` and `pendingApproval`.
**`RotationHold`** gains the two reasons a rotation now waits on an admin change:
```kotlin
/** A change to who is an admin, or a removal of a holder, is being signed or has not landed yet. */