Repository navigation
feat(solo): grant chat admin access to owned agents - #3647
Conversation
Promote every agent addressed in a new Solo chat through the existing member-administration API before releasing its opening message. Keep workspace-only agents and later additions as ordinary participants. Retain setup intent in the existing local creation receipt. Recover exact promotion commands across interrupted delivery without restoring later demotions or removals; keep expired unrecorded grants explicit. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Wait for the fixture shortcut installed by React before invoking it. Page load alone does not establish that its registration effect ran. Keep both geometry journeys and their assertions unchanged. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Exercise sequential grants, lost acknowledgments, command shape and fixed signing identity/timestamp in the existing session delivery journey. Retain durable restart and exact command replay there, plus focused stale receipt removal, access changes, expiry and invalid-intent helper checks. Remove the duplicate helper journey and its unused fixture data without changing the opening-agent admin behavior or publication gate. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Count only the selected community's preference decoding when checking a warm Messages return. Background unread loading for another community must not count as a re-fetch of the retained sidebar snapshot. Drain held route continuations before removing their interception so cleanup does not auto-continue a request before its handler resumes. Preserve the existing frame, selection, scroll and zero-count assertions. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Merge main and pass the creation signer to the member administration template. Admin promotion commands and recovery IDs retain their existing shape. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Request Admin in the existing membership addition for new agents in an owned Solo chat. Keep existing members and saved Bot/Admin retry events unchanged, while preserving other channel admission defaults. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Integrate the host sharing picker before validating later-agent grants through the existing Chat access caller. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Compare optional role tag values directly while retaining exact Bot and Admin grants for retries. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
wesbillman
left a comment
There was a problem hiding this comment.
🤖 Star Lord: changes needed at 549140a (two P2s); the automatic Admin default also needs a core-team decision. Source review only; security and product review coverage was partial.
| : undefined, | ||
| // Unguarded, so a restart can retry it like any New chat. | ||
| ...(region ? [{ labels: [region] }] : []), | ||
| { admins: recipients, ...(region ? { labels: [region] } : {}) }, |
There was a problem hiding this comment.
🤖 Star Lord — Product-scope decision: this grants full chat Admin to every opening recipient, and addAgents extends that default to later owner additions. Core-team agreement on this expanded permission default is unconfirmed in the PR. Please confirm full Admin as intended core behavior; otherwise retain ordinary agent admission pending that decision.
There was a problem hiding this comment.
🤖 At ae87bf2f3e, automatic Admin is limited to agents whose current signed profiles verify that the Solo chat owner owns them. This applies consistently to opening recipients, owned workspace defaults, and new additions through the composer or Chat access. Shared or other-owned agents receive ordinary initial Member admission or later Bot admission; existing members are not promoted.
Taylor explicitly chose the owned-agent restriction and workspace-default consistency. Full Admin remains intentional for those owned agents, using the existing role to let them rename and administer the owner's chat; it includes powers beyond rename. This narrows the policy raised here, but does not establish core-team sign-off. Leaving this discussion open for maintainer confirmation of that narrowed default.
kalvinnchau
left a comment
There was a problem hiding this comment.
🤖 One additional access-revocation race; existing admission and recovery findings are not duplicated.
| if (signed.id !== id || signed.pubkey !== create.pubkey) | ||
| throw new Error("The signer changed the chat admin command."); | ||
| try { | ||
| await writer.publish(signed, signal); |
There was a problem hiding this comment.
🤖 [P2] Make the first opening grant conditional on unchanged access. If the owner removes an opening agent after the roster read but before this asynchronous grant is published, the unrecorded Admin command restores that agent before the opening message is released. The fixed command ID only prevents a second application; no expected-membership condition is sent with the first application. This was reproduced with the actual helper and modeled reader/publisher, and relay source confirms an unrecorded PUT clears removed_at and applies the requested role. Use an atomic conditional grant or creation contract that preserves intervening revocation; another client-side read cannot close the race.
There was a problem hiding this comment.
🤖 This is a valid limitation and remains unfixed at ae87bf2f3e. Taylor chose to keep Solo composed from existing relay primitives and defer a relay-contract change for this narrow opening-setup race. The PR description now records the race and recovery: a removal between the roster read and the first unrecorded grant can be undone; after the pending grant is recorded, removing the agent again persists. That recovery cannot undo access during the interval.
Atomic initial roles or conditional membership commands would be needed for stronger revocation semantics. The ownership-transfer and shared-abandonment repairs do not close this cross-device membership race. Leaving this thread open for reviewer disposition as a documented limitation, rather than marking it fixed.
Admit only the exact single-Admin addition with its original client ID through the existing member-administration boundary. Keep generic signing closed and verify exact signed-event replay through the broker after restart. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Make expired delivered setup an explicit recovery-owner removal. Preserve the chat, current roles and gate on storage failure; cancel an active grant before publication when its receipt is removed. Expose abandonment across the expiry deadline without adding a timer. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Require a new explicit Send after setup abandonment. Cover timestamp rejection of the exact expired event without changing it, then user-initiated delivery with current roles. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
kalvinnchau
left a comment
There was a problem hiding this comment.
🤖 Cross-window abandonment still permits active setup to publish.
Serialize exact durable setup ownership with dismissal through grant publication and final retirement. Sign outside the lock, preserve recovery after failed storage, and discard stale local ownership before another save can reclaim it. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
kalvinnchau
left a comment
There was a problem hiding this comment.
🤖 One dismissal regression found.
## Why Two WebKit browser journeys fail now and then in CI on branches that cannot affect them. One failed test fails its shard and `CI required`, because the Playwright config sets `retries: 0`, and the only recovery is a manual re-run. Both are races in the tests themselves, not product defects. - `tests/browser/relay-recovery.spec.mjs:9`, "relay reads recover automatically after the network returns". - `tests/browser/solo-legacy-invitation.spec.mjs:49`, "Outbox Retry reconciles a recorded then removed Solo invitation without replaying it". This PR is test-only. It changes those two spec files (+26 −9) and no production code. No journey is added or removed. Both failures surfaced together in one CI run on #3677 (run 43995560292, attempt 1). That PR did not cause them. It renames a presence label in the profile panel, which neither journey opens or asserts. The failed jobs passed on re-run at the same commit, and the same failure signatures appear on other branches, listed below. ## relay-recovery: the wait was satisfied by another community's read **The failure.** `toBeInViewport` reports "element(s) not found" for the connection notice, on WebKit shard 5/18. Example: run 43995560292, job 133746953063. **The race.** The test cuts the network, waits for the open channel's catch-up read to meet the outage, jumps the clock 30 s, and expects the connection notice to stay up. The wait accepted a refused `/query` from any community. In the CI trace the second community's background reads were refused first, so the wait passed on one of them and the clock jumped before the open channel's own read was refused: | ms after the outage began | Event | |---|---| | +26 to +77 | First five refused requests, all for the second community | | +124 | The wait passes, on a second-community `/query` | | +146 to +271 | `clock.fastForward(30_000)` | | +272 | Notice visible | | +545 | First refused `/query` for the open channel's community | | +881 | The failing assertion starts. The notice is gone and stays gone for 10 s | `createRecovery` in `src/features/relay/recovery.ts` hides the notice as soon as no source is failed or busy. Once the live socket returns there is an instant where nothing is failed, just before the open channel's read is queued and refused. That later refusal starts a fresh 30 s notice timer, which the test's clock never advances. **Why now.** #3459 added a background session for other communities, which is the source of the early second-community refusals. In a sweep of CI runs from 14 to 17 Nov, this exact signature failed in 5 of the 126 completed runs created after #3459 merged, and in none of the 660 completed runs created before it. **The fix.** The wait now passes only when a refused `/query` for the primary community carries the open channel's timeline head. The filter test is the one `isChannelHead` uses in `src/features/relay/session.ts`, `depth_limit` clause included. The comment above the wait already asked for this. Once that read is refused, the channel's head stays failed or pending while the outage holds, so recovery cannot go idle and the notice cannot clear before the network returns. ## solo-legacy-invitation: a reload while the app was still booting **The failure.** `page.reload: WebKit encountered an internal error`, on WebKit shard 6/18, followed by the fixture's console-error check failing on the resulting "Failed to load resource" message. Example: run 43995560292, job 133746953195. **The race.** Each colour-mode pass did `goto`, a `localStorage` write, then `reload`. In the CI trace the reload began 39 ms after `goto` resolved, while the app was still booting. The trace shows the in-flight boot requests cancelled at that moment, then the document request hanging 3.5 s and failing. #1972 diagnosed and fixed the same pattern in `settings.spec.mjs` and `account-profile.spec.mjs`, but not in this spec. **The fix.** As in #1972, the mode is written by an init script before the document loads, and the boot reload is gone. The second pass adds a second script. Scripts run in the order added, so the last mode wins. The reload the test is about, after Retry, is unchanged. The existing `data-color-mode` assertion still proves each pass booted in its mode. **Known limit.** The trigger is established from the trace and matches #1972's diagnosis. The reason WebKit fails the document request is not established. ## Occurrences on other branches From a sweep of 1,196 CI workflow runs created between 2026-11-14 01:25Z and 2026-11-17 01:49Z, excluding the #3677 run. History before 14 Nov was not swept. The 12 Nov run was found by hand. | Signature | Other occurrences | Where | |---|---|---| | `relay-recovery.spec.mjs:9`, line 83 on `main`, `toBeInViewport` "element(s) not found" | 4, all WebKit 5/18 | Runs 43969555290 (#3050), 43988980663 (#3035), 43990605700, 43991562525 (#3043), between 16 Nov 22:35Z and 17 Nov 00:57Z | | `solo-legacy-invitation.spec.mjs:49`, `page.reload: WebKit encountered an internal error` | 0 in the window, 1 older | Run 43294609776 attempt 1 on #3400, 12 Nov, job 131450781682 | One more run failed `relay-recovery.spec.mjs:9` at other lines: run 43683311686 on #3551's own branch, which rewrites the test's navigation. It is not counted above. ## Evidence All local: macOS 27.2, Playwright 1.63.0, on `23d1d7045b` plus this change, with `--no-deps` and the config's two workers. | Check | Result | |---|---| | relay-recovery, forced CI ordering, previous wait | 20 of 20 fail, 10 Chromium and 10 WebKit, each at the `toBeInViewport` assertion with "element(s) not found" | | relay-recovery, forced CI ordering, new wait | 20 of 20 pass, 10 Chromium and 10 WebKit | | relay-recovery, committed spec, `--repeat-each=10` | 20 of 20 pass, 10 Chromium and 10 WebKit | | solo-legacy-invitation, committed spec, `--repeat-each=10` | 20 of 20 pass, 10 Chromium and 10 WebKit | | solo-legacy-invitation, init script removed | The "dark" pass fails on both engines at the `data-color-mode` assertion: expected "dark", received "light" | | `pnpm typecheck` | passed | | `pnpm lint` | passed, no notes in the touched files | | `biome format` on the two files, `git diff --check` | no changes, clean | - **Forced ordering.** The two forced runs used temporary copies of the spec outside the repository. Each copy had the same two additions: a refused second-community `/query` recorded at the moment of the outage, and a one second pause before the `toBeInViewport` assertion, as on a slower runner. The only difference between the two runs is the wait. - **Init script removed.** This run shows the init script is what sets the mode, and that the `data-color-mode` assertion is live. ## Not proven and not run - **No fail-before run for solo-legacy-invitation.** The CI failure has not been reproduced on macOS WebKit. The 20 passing runs show the journey still works, not that the flake is gone. That proof is the error staying absent from CI. The known rate is low: two occurrences, on 12 and 17 Nov. - **Nothing ran on Linux WebKit.** Hosted CI runs Linux WebKit. Every run above is macOS. CI on this PR is the first Linux run of the change. - **The relay-recovery failure was reproduced by forcing the order.** The unmodified spec did not fail locally without forcing. - **Not run locally.** The rest of the browser suite and the unit tests. - **Pre-push hook.** The branch was pushed with `git push --no-verify`, so the hook did not run. - **Base.** The checks ran on `23d1d7045b`. `main` has since gained one commit, a release CI change (#3665) that touches neither spec. The branch was not rebased. - **Human testing.** No human has tested this, so the review-completed marker is not set. ## Not included, and related PRs - **`find-on-screen.spec.mjs` is deliberately left out.** A third WebKit flake failed in the same run: `window.openFind is not a function`. Commit `c111ae8c6d` "test(search): await find shortcut registration" in open PR #3647 already fixes it by waiting for the hook to be registered. Changing the same lines here would only conflict with it. - **Draft PR #3551 carries an equivalent relay-recovery change.** It sets a flag when a refused `/query` carries a `top_level` filter for the channel. That PR is a 628-file draft that currently conflicts with `main`, so it is not a near-term fix. - **No other open PR was found that fixes either race.** The open PRs were checked by changed file path during the investigation. #2363 and #3551 edit `solo-legacy-invitation.spec.mjs` but leave the boot reload in place. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Signed-off-by: Matt Toohey <contact@matttoohey.com> Co-authored-by: Claude Fable 5.2 <noreply@anthropic.com>
Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> * origin/main: test(browser): deflake relay-recovery and solo-legacy-invitation (#3681) Align message and composer typography (#2990) fix(repos): fix commit counts, file sizes and commit heading copy (#3686) fix(usage): count standalone timer and watch turns (#3518) Avoid rewriting unchanged artifact indexes (#3672) ci(release): keep release Rust caches from being evicted (#3665) Give the community join dialog a navigation visit (#3063) Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Apply verified profile ownership to initial members and new Solo additions. Include owned workspace defaults without addressing them in the opening message, and preserve recorded grants and exact signed invitation retries. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
kalvinnchau
left a comment
There was a problem hiding this comment.
🤖 One new ownership-transfer finding.
Honor newer verified agent profiles before each new role decision and fence opening publication across roster reads, signing and recovery locking. Preserve recorded grants, saved invitations and abandonment. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
kazemek21
left a comment
There was a problem hiding this comment.
Kyle reviewed the PR and the Nexus review-tracker notes. Approved with the non-blocking ownership-freshness comment.
— Posted by Codex (gpt-6.1-sol) on behalf of kylez
Read each new grant target through the fresh strongly consistent profile boundary, and reject cached authority when the fresh response has no matching signed head. Preserve recorded opening grants and exact saved invitation retries. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Preserve DM history-choice and fork coverage alongside Solo owner-role and verified ownership fixtures. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Apply the pinned formatter to the merged Solo and DM roster expression so CI can continue past its static check. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
wesbillman
left a comment
There was a problem hiding this comment.
🤖 Carl, an automated reviewer, commenting via Wes's GitHub account.
Changes requested at cd09311f75. There is one P1: abandoned setup can still publish. There are also two P2s, both about Solo opening setup that can't finish leaving the user stuck. Details are in the inline threads. This was a Court review with security/auth, persistence/concurrency, product/docs and integration lanes. The P1 was reproduced in Chromium and WebKit.
Security/auth: no new defect found. The client-ID Admin broker exception is narrowly scoped, and ownership authority comes from the admitted signed kind-0 head with a verified NIP-OA owner. That was a source-only read.
Validation gaps: native signing of later-addition Admin through the ordinary writer, and acceptance by the deployed relay, are still unexercised. The PR already acknowledges both.
Non-blocking simplicity note: a smaller design may exist. Opening grants could be ordinary queued single-Admin additions, using the path this PR already adds for later additions, with a derived rule that a Solo kind 9 waits while an earlier Admin addition for that channel is pending. That could remove create recovery, promoteSoloAdmins reconstruction, prepareOpening, withRecovery/finishRecovery and the abandonment UI. It hasn't been verified against ordering after a restart, so treat it as a question, not a requirement.
Design should review: Should Abandon admin setup have a confirmation, as message Remove does? After abandonment the original opening text can't be retried, so should it be offered back to the composer? Should the UI explain why an owned agent without a NIP-OA profile got no Admin?
Exit criteria: a stale journal write can't bring back a durably abandoned receipt, with a regression test; a user stuck in opening setup has a way to continue right away, and the docs match it; the setup row is labeled before expiry and doesn't show the message-confirmation error.
Treat a known journal row as an update in the same IndexedDB transaction, including during legacy migration. A delayed creation echo cannot re-create a receipt removed by another window. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Label setup in Outbox and confirm abandonment once the chat is created. Retain the chat and granted roles and let the user retry the original opening message. Keep the existing grant deadline and clarify recovery in help. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
Keep the upstream sidebar regression fixture, which already isolates preference reads to Primary and drains held handlers. Preserve the Solo opening recovery fixes. Co-authored-by: Carl <acda9e433d19dcd0e6b6840f7f4b98f3a56f1fab98049d444c087019e6d36560@feedback.communities.buzz.xyz> Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
|
🤖 @wesbillman The three opening setup fixes are published in
Full The queue reuse idea looks promising if the queue can persist the complete grant list with the create and enforce ordering and cancellation after restart. The current queue can replay individual events, but a scan for earlier pending grants cannot detect grants that were never saved. |
|
🤖 @wesbillman I tried your suggestion with ordinary Outbox Admin operations. The prototype reused the write path and replayed a partial setup after restart without restoring an earlier demotion. It added 98 net production lines with the existing receipt path retained for comparison. The fresh-start comparison exposed two gaps. With a grant signature held, Chromium and WebKit both reached a confirmed create but had no way to abandon setup. The same test on the PR head stopped the grant and let Retry send the original message. The prototype also skipped the shared publication lock used by the ownership-transfer regression. To preserve those behaviors, the general queue would need to persist the full set of intended grants with the create, hold the first message until those grants are confirmed or explicitly abandoned, and serialize grant publication with cancellation across windows. Otherwise a missing queue row can look like finished work. The current opening receipt already owns that state and lock. I’d keep it for this PR since moving those responsibilities into the shared queue would expand the change. |
wesbillman
left a comment
There was a problem hiding this comment.
🤖 Carl, an automated reviewer, commenting via Wes's GitHub account.
Re-review at be212e10df: no remaining blockers from my previous review.
- P1 (stale echo could bring back abandoned setup): fixed by
a8f953d3fa. Rows this window already knows about are now updated only if they still exist, checked in the same transaction. I reran the earlier two-Outbox IndexedDB/Web Locks probe against this head, and it now passes in both Chromium and WebKit: the abandoned receipt stays removed, and neither publication nor completion runs. Theforcesave is used only by the explicitrecoveraction, which is intended. - P2 (blocked opening setup left the user stuck): fixed by
7797070c00. Abandon is offered with a confirmation as soon as the create is delivered, the original opening message can then be retried, and the docs and error copy match. The transfer spec covers abandon followed by Retry. - P2 (unlabeled setup row and wrong Remove error): fixed. Setup receipts are labeled, and a pending setup row no longer shows a Remove that can only fail.
CI is green: 73 checks pass and 1 is skipped. The remaining gaps are the same as before: native signing of the later Admin addition, and acceptance by the deployed relay. The simplicity note and the design questions from my earlier review are still optional.
* origin/main: (27 commits) fix(channels): move unarchive into the archived pill (#3763) Retry the protected Claude fixture download (#3086) test(search): fix main typecheck in scoped search tests (#3780) fix(messages): copy a message's author and time as one line above its text (#3598) fix(agents): copy the npub from the card menu's "Copy public key" (#3666) fix(presence): call the online state "Online" in the profile to be consistent (#3677) fix(shell): say availability, not status, when availability is unknown (#3688) test(browser): warm up the window-chrome fixture before navigating (#3690) AIDA-2282: Reject legacy CLI calls to the desktop app (#2014) fix(messages): highlight only selected text inside Markdown boxes (#3734) Add committed artifact change notifications (#3759) test(reactions): measure the action bar only after it opens (#3281) fix(dm): create a DM only when its first message is sent (#3682) feat(solo): grant chat admin access to owned agents (#3647) feat(messages): copy forwards into composers (#3632) feat(media): add image and video context actions (#3740) feat(solo): archive a workspace's inactive chats (#3717) fix(search): make ⌘F and in: show one conversation's results the same way (#3676) feat(github): offer held pull request states to other plugins (#2141) fix(agents): catch up an agent's mentions, in their own pass (#1634) ...
…diagnostics * origin/main: (44 commits) fix(channels): move unarchive into the archived pill (#3763) Retry the protected Claude fixture download (#3086) test(search): fix main typecheck in scoped search tests (#3780) fix(messages): copy a message's author and time as one line above its text (#3598) fix(agents): copy the npub from the card menu's "Copy public key" (#3666) fix(presence): call the online state "Online" in the profile to be consistent (#3677) fix(shell): say availability, not status, when availability is unknown (#3688) test(browser): warm up the window-chrome fixture before navigating (#3690) AIDA-2282: Reject legacy CLI calls to the desktop app (#2014) fix(messages): highlight only selected text inside Markdown boxes (#3734) Add committed artifact change notifications (#3759) test(reactions): measure the action bar only after it opens (#3281) fix(dm): create a DM only when its first message is sent (#3682) feat(solo): grant chat admin access to owned agents (#3647) feat(messages): copy forwards into composers (#3632) feat(media): add image and video context actions (#3740) feat(solo): archive a workspace's inactive chats (#3717) fix(search): make ⌘F and in: show one conversation's results the same way (#3676) feat(github): offer held pull request states to other plugins (#2141) fix(agents): catch up an agent's mentions, in their own pass (#1634) ...
…utomatic * origin/main: (27 commits) feat(bestie): show the last 7 days of cost in the Bestie tab (block#3499) test(perf): measure the cost of background channel traffic (block#3727) fix(channels): make renaming and access changes easy to find in Channel settings (block#3679) fix(channels): move unarchive into the archived pill (block#3763) Retry the protected Claude fixture download (block#3086) test(search): fix main typecheck in scoped search tests (block#3780) fix(messages): copy a message's author and time as one line above its text (block#3598) fix(agents): copy the npub from the card menu's "Copy public key" (block#3666) fix(presence): call the online state "Online" in the profile to be consistent (block#3677) fix(shell): say availability, not status, when availability is unknown (block#3688) test(browser): warm up the window-chrome fixture before navigating (block#3690) AIDA-2282: Reject legacy CLI calls to the desktop app (block#2014) fix(messages): highlight only selected text inside Markdown boxes (block#3734) Add committed artifact change notifications (block#3759) test(reactions): measure the action bar only after it opens (block#3281) fix(dm): create a DM only when its first message is sent (block#3682) feat(solo): grant chat admin access to owned agents (block#3647) feat(messages): copy forwards into composers (block#3632) feat(media): add image and video context actions (block#3740) feat(solo): archive a workspace's inactive chats (block#3717) ... Signed-off-by: Joah Gerstenberg <joah@squareup.com>
…place * origin/main: (200 commits) feat(builderlab): list stored conversations above the live activity feed (block#3607) feat(bestie): show the last 7 days of cost in the Bestie tab (block#3499) test(perf): measure the cost of background channel traffic (block#3727) fix(channels): make renaming and access changes easy to find in Channel settings (block#3679) fix(channels): move unarchive into the archived pill (block#3763) Retry the protected Claude fixture download (block#3086) test(search): fix main typecheck in scoped search tests (block#3780) fix(messages): copy a message's author and time as one line above its text (block#3598) fix(agents): copy the npub from the card menu's "Copy public key" (block#3666) fix(presence): call the online state "Online" in the profile to be consistent (block#3677) fix(shell): say availability, not status, when availability is unknown (block#3688) test(browser): warm up the window-chrome fixture before navigating (block#3690) AIDA-2282: Reject legacy CLI calls to the desktop app (block#2014) fix(messages): highlight only selected text inside Markdown boxes (block#3734) Add committed artifact change notifications (block#3759) test(reactions): measure the action bar only after it opens (block#3281) fix(dm): create a DM only when its first message is sent (block#3682) feat(solo): grant chat admin access to owned agents (block#3647) feat(messages): copy forwards into composers (block#3632) feat(media): add image and video context actions (block#3740) ... Signed-off-by: Joah Gerstenberg <joah@squareup.com> # Conflicts: # .github/workflows/desktop-build.yml # browser-host/vite-config.test.mjs
Category: improvement
User Impact: Your own agents automatically receive Admin in Solo chats, including agents included through workspace defaults.
Problem: Solo agents can reply but lack permission to rename or administer the chat; automatic grants also need a consistent ownership rule for addressed agents and workspace defaults.
Solution: Grant Admin only to agents whose signed profiles verify that the chat owner owns them, both at creation and for later additions through the composer or Chat access. Include owned workspace defaults without addressing them in the opening message, using existing relay commands and durable Outbox recovery while preserving existing roles and exact saved grants.
File changes
src/features/solo/SoloDraft.tsx
Freeze the verified owned subset of all initial members, including workspace defaults, separately from the opening message recipients.
src/features/relay/channel-writes.ts
Coordinate recoverable opening setup and read each new automatic-grant target through the fresh, strongly consistent signed-profile reader. Require the admitted ownership head in that response, including before choosing a later addition’s role; failed reads block new writes and empty reads cannot reuse cached authority. Preserve exact signed invitation retries. Sign opening grants outside the receipt lock, then guard publication and final retirement with shared durable ownership; refuse a missing guard rather than publish without one.
src/features/relay/solo-admins.ts
Verify ownership from the current signature-admitted NIP-OA profile using the existing profile directory and verifier. Reconstruct exact opening grants, guard each unrecorded grant against profile replacement through roster reads, signing and publication locking, and confirm recorded IDs without restoring later role changes. Recognize and validate the saved setup in every delivery state. Explain how to continue when the remaining grants are blocked. The original grant deadline still applies.
src/features/relay/session.ts
Pass the existing administration writer, profile queries and viewer into channel writes, and gate opening-message publication before early local delivery. The FOUNDATION change is seven added lines, including two existing dependency fields for ownership; no Solo policy import.
src/features/relay/solo-admins.test.ts
Cover valid ownership, foreign ownership, unadmitted profiles, metadata-only hints and profile-head replacement. Distinguish unrecorded grants after ownership changes from exact recorded confirmation. Cover received transfers between targets and across roster reads, signing and publication locking. Retain access, expiry, abandonment and failure coverage.
src/features/relay/solo-admins.integration.test.ts
Exercise sequential owned grants, including a quiet workspace default, lost acknowledgments, held delivery and restart. Hold a signature across expiry and durable abandonment, proving no further grant or automatic message delivery occurs before a new explicit Send. Preserve the expired queued event, reject its exact Retry at the modeled relay timestamp boundary, and deliver only the fresh message. Receive a verified ownership transfer while waiting for the shared publication lock and retain recovery without publishing. Preload cached ownership, then transfer it only at the modeled relay or return missing/unavailable profile data: no new opening grant or message may publish.
src/features/solo/SoloDraft.test.tsx
Verify owned workspace defaults and addressed agents follow the same Admin rule, shared recipients do not request Admin, and quiet defaults remain absent from opening message recipients. Preserve existing draft, region and navigation coverage.
src/features/relay/session-agent-admission.test.ts
Cover owned/shared/missing-proof and mixed additions, Owner/Admin/Member viewers, private/public Solo chats and Guest defaults. Refresh cached transferred ownership and cover missing/unavailable profile reads; exact saved Admin retries still work when profile reads are unavailable. Retain exact Bot/Admin events across role and profile ownership changes; preserve ordinary-channel defaults, existing members and failure/cancellation checks.
src/bundled/channels/ChannelMembersDialog.test.tsx
Verify Chat access requests Admin for owned agents and Bot for shared agents without sending a message, in private/public Solo chats. Use real signed ownership profiles and preserve interaction/retry and no-channel-role identity assertions.
tests/browser/find-on-screen.spec.mjs
Wait for React's shortcut registration, preserving both existing geometry journeys and assertions.
docs/buzz-help.md
Explain how to abandon blocked setup and retry the opening message after creation is confirmed.
docs/solo/README.md
Document exact setup retries, later additions and shared ownership across publication and abandonment; accepted grants remain in place.
docs/solo/sharing.md
Explain the shared composer/Chat access grant, existing-role preservation and saved retries.
src/features/relay/transport.ts
Route the exact single-Admin Outbox addition, including its saved client ID, through the existing browser member-administration sign/publish boundary.
src/features/channel-members/administration-protocol.ts
Recognize that narrowly bounded Admin-addition shape using existing administration validation; exclude self, batch and ownership grants from this path.
browser-host/relay-broker.mjs
Admit the saved Admin-addition shape on the dedicated member-administration routes. Preserve the generic writer restrictions and current-socket publication requirement.
browser-host/relay-broker-api.test.mjs
Exercise actual HTTP signing and publication through Outbox. Persist/restart after proven non-delivery and verify the exact signed event is replayed; extend existing negative controls.
src/bundled/channels/OutboxStatus.tsx
Label opening setup throughout delivery. Offer a confirmation once the create is delivered, then use the existing durable recovery-owner removal. Explain retained roles and how to retry the opening message.
src/bundled/channels/OutboxStatus.test.tsx
Exercise the setup label, unavailable actions on an unconfirmed creation, early confirmation and cancellation. Prove that failed storage preserves setup, successful abandonment keeps the chat, and messages work before and after restart without grants.
src/features/relay/outbox.ts
Provide an exact durable recovery-owner guard shared with dismissal. Retain ownership through dependent publication and final retirement, and relinquish stale local receipt ownership after another window removes it. Dismissal alone treats an already-absent shared receipt as success; changed ownership and dependent publication/completion still reject.
src/features/relay/outbox-storage.ts
Check row existence within the write transaction when updating a known event, including legacy migration. Late echoes cannot reinsert a durably removed receipt.
tests/browser/outbox-storage.spec.mjs
Exercise two real Outboxes with shared IndexedDB and Web Locks. After durable removal, a late creation echo leaves the receipt absent and both dependent publication and completion reject. Cover a migrated journal and overlapping legacy hydration.
src/features/relay/outbox-recovery.test.ts
Cover fresh-local stale ownership, prevention of later journal resurrection, publication/dismissal ordering, strict completion after abandonment, duplicate dismissal success, and rejection of different shared recovery keys or values.
tests/browser/fixture.mjs
Use genuine ownership delegations for owned and shared agent profiles. Opt in to creation/grant readback, independently controlled receiver time and newer signed ownership profiles for setup journeys; opening fixtures retain strict Admin checks.
tests/browser/solo-ownership-transfer.spec.mjs
Hold the first real signing response, admit a newer verified ownership profile through the production reader, then check the next opening/later grant. Opening setup stops and retains the message. After confirming abandonment before expiry, retry delivers the exact opening event with current roles. A new later addition uses Bot. Exercise both engines.
tests/browser/solo-admin-abandonment.spec.mjs
Exercise the production app/broker, shared IndexedDB and Web Locks. Cover cross-window abandonment at expiry and same-window abandonment before expiry, including keyboard focus and cancellation. Keep the failed-storage, exact saved publication and later explicit Send cases. A restored-opening journey grants a quiet owned default without promoting or changing the exact message addressed to its shared recipient.
tests/browser/message-management.spec.mjs
Exercise two production app windows discarding one orphaned follow-up through the real shared journal and message confirmation. Both dialogs close without publication after the second dismissal.
src/features/relay/testing.ts
Provide a real signed NIP-OA profile helper for ownership fixtures; custom verified transports admit those records through eventDto.
src/bundled/channels/ChannelsPage.solo.test.tsx
Isolate the ownership decision from intentionally pending display-profile loads in navigation fixtures. Preserve all 111 history, restoration, draft-route and background-completion scenarios and assertions.
Try it
member_listshould show the creator as Owner, both owned agents as Admin and the shared agent as Member. The opening message addresses only the agents selected in the composer.Opening setup recovery
The built browser app with sample data, using the production broker and a fixture relay.
Known limitation: concurrent removal during opening setup
The first automatic Admin grant can re-add an agent removed after the app's membership check but before grant publication. Once that pending grant is recorded, removing the agent again persists; recorded opening grants are not reapplied. Membership recovery does not undo access the agent had during that interval. This timing was reproduced in a controlled helper test, not observed as a live incident; its real-world frequency has not been measured.
Solo composes existing relay creation and membership commands. A stronger guarantee that concurrent removal always wins would require general relay support, such as atomic initial roles or conditional membership commands; that work is outside this client PR. Shared setup-abandonment ownership remains enforced separately.
Validation and limits
be212e10dfintegrates main throughc788428a40. Main already carries the sidebar test fix for Primary preference requests and pending route handlers. The combined tree preserves main’s test and the Solo recovery implementation. Fullpnpm checkand 44 Chromium/WebKit executions across four complete browser files pass on the merged commit. All required push hooks passed, including TypeScript and related unit tests (1,101.61 s) and design checks (6.40 s). Hosted CI is pending.7797070c00passed 192 tests across seven complete files, 24 Chromium/WebKit executions across three complete browser files, and repository-wide Biome.ae87bf2f3e. Six real-session cases cover cached transferred ownership and missing/unavailable profile reads; saved Admin retries retain their exact event even when profiles cannot be read. New automatic grants make one fresh, strongly consistent profile read per target and guard its admitted signed head through publication. Recorded grants and exact saved invitations bypass new authorization.ae87bf2f3e: 1,415 tests across 55 files and 158 browser executions; prior integrated-head checks at39272ddd01: 182 tests and 12 browser executions. These are historical snapshots, not current-head totals. Main's DM history/fork behavior and Solo Owner-roster assertions are preserved.The owner-precedence relay fix, block/buzz#9592, is merged and remains independent of these app repairs.
Replaces #3536. The paired relay proposal, block/buzz#9495, is closed.