Commit Graph

2604 Commits

Author SHA1 Message Date
Logan Johnson
3a062ea7f2 test(desktop): prove native deletion before draft scope cleanup
Capture the real editor document without polling before the rapid switch; add persisted-first controls without replacing unsaved coverage.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 19:17:47 -04:00
Logan Johnson
524d92cd26 test(desktop): await native block selection before typing
Apply sealed 6492 test-only readiness correction; production is unchanged.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 19:08:03 -04:00
Logan Johnson
c26596866a fix(desktop): retire claimed automatic composer focus
Apply sealed autofocus 5c122833 candidate without speculative refactoring.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:55:17 -04:00
Logan Johnson
0bf787c1ae fix(desktop): abandon pending mentions when live eligibility lapses
Keep pending Retry non-actionable while stale query errors remain. Cancel within the existing admission owner when its exact live-choice validity is lost, so later Retry cannot revive an older prepare operation. Preserve the independent 15-second timeout proof on a closed-picker pin, which has no open-request expiry.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:55:08 -04:00
Logan Johnson
aaa708daac fix(desktop): bind mention cancellation to mounted editors
The owning editor hook now follows the public mount/unmount/destroy
lifecycle: cancellation listeners attach only to a live mounted view,
detach from the captured DOM on retirement or replacement, and pending
admission work is cancelled rather than committing against a destroyed or
replaced editor. Adds a real useEditor/EditorContent regression and
presence-baselined browser guards for the profile and virtualization routes.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:56 -04:00
Logan Johnson
14c900a343 test(mentions): prove editor cancellation with native range restoration
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:56 -04:00
Logan Johnson
0e1c83e830 chore(desktop): remove redundant emoji section heading
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:56 -04:00
Logan Johnson
801cb94fcd fix(desktop): keep mention choices safe when access changes
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:56 -04:00
Logan Johnson
ed502a18b9 test(desktop): verify mention ranking resets through community switch
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:40 -04:00
Logan Johnson
1d126d4d65 feat(desktop): rank next mention snapshot by admitted choices
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:40 -04:00
Logan Johnson
479bbe0f17 fix(desktop): retain exact nonmember mention evidence
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:54:40 -04:00
Logan Johnson
b1a429e5c4 fix(desktop): preserve mention eligibility through retry settlement
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 18:25:04 -04:00
Logan Johnson
f1af1b88c6 test(desktop): clear the explicit-picker draft with native keypresses
The explicit-picker setup in the relay-agent directory-errors spec
cleared the seeded draft with fill(""), whose programmatic selectAll can
lose the selection to ProseMirror's own selection sync and leave
"@quinn" behind in CI, exhausting retries at the picker-empty
assertion. Clear the draft with native ControlOrMeta+A and Backspace so
the editor applies both steps in its own transaction, and gate
immediately on toBeEmpty before opening the picker. Every original
directory-error, disabled-row, Tab-completion and retry-recovery
assertion is unchanged; no production code, timeout or mock change.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 11:37:27 -04:00
Logan Johnson
be1d594f46 test(desktop): clear the parked error toast before the DM retry
The first send parks the pointer over the bottom-right error toast, which
overlaps the send button; Sonner pauses its dismiss timer while the toaster
is hovered, so the native retry click is intercepted for the full timeout.
Move the cursor away and wait for the transient toast to clear naturally
before retrying, mirroring the adjacent agent-startup-failure test. The
injected first-send failure and every destination assertion are unchanged.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-09 10:25:06 -04:00
Logan Johnson
27593788c4 test(desktop): bind workflow message owner and settled geometry
Keep the outgoing trigger input separate from the new message textarea, sample match controls together after inspector settlement, and verify the persisted original trigger and step text before reopen.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 16:45:17 -04:00
Logan Johnson
3825f894d0 test(desktop): settle hover surfaces before comparing colors
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 15:47:16 -04:00
Logan Johnson
a6fb55dde4 fix(desktop): settle required search after directory errors
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:50:18 -04:00
Logan Johnson
9e5a546fd9 fix(desktop): wait for people search behind cold directories
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:50:18 -04:00
Logan Johnson
0464384b67 test(desktop): hold initial agent directory until assertions
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:50:18 -04:00
Logan Johnson
ada2df7878 refactor(desktop): extract composer frame scroll callback
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:43:04 -04:00
Logan Johnson
bf6144a3ba refactor(desktop): install stable mention choices per request
Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:43:04 -04:00
Logan Johnson
75f61d7d47 test(desktop): validate one-time DM mentions in editor prefix
Move the existing later-slice DM-loading fixture correction to the editor prefix. Assert no premature signing and exact final recipients without treating a one-time mention as an automatic address.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:43:04 -04:00
Logan Johnson
b4a4f6f243 test(desktop): model Welcome collision membership delivery
Preserve mock-created team identity across create/list so Welcome reuses its starters. Explicitly seed a separate same-name Fizz and model the member_joined event omitted by mock add-members. Keep ambiguity, draft, no-publication and sole-starter recipient assertions intact.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:43:04 -04:00
Logan Johnson
30bc57da82 refactor(desktop): share mention send error presentation
Extract the identical authorization-aware error presentation from both send failure paths so normal formatter output respects the file-size ratchet.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:22:06 -04:00
Logan Johnson
85ac1bc6a2 fix(desktop): revalidate current access and exact team members
Package existing reviewed repairs in the authorized seven-slice dependency stack. Preserved model A; experiment excluded.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-08 14:21:55 -04:00
Logan Johnson
bb8cca21e1 test(desktop): own exact recipient restoration and publication evidence
Keep one full storage-to-transport witness and both local restoration checks. Select the destination fixture by pointer so this prefix does not depend on the later native Enter repair.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-04 07:11:24 -04:00
Logan Johnson
d0c3498409 fix(desktop): preserve draft authority and generated mention labels
Package existing reviewed repairs in the authorized seven-slice dependency stack. Preserved model A; experiment excluded.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-02 11:35:24 -04:00
Logan Johnson
b7f124f7fc fix(desktop): keep closed message actions from taking edit focus
Backport the independently reviewed 646f30febd436d8a10a2f531f38a4ac9d2912064 fix and its regression to published PR1 db566eb5. Keep the closed-menu production owner and browser assertions unchanged; register the test next to mention-recipients on this base.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 21:59:44 -04:00
Logan Johnson
db566eb57d fix(desktop): retain drafts after synchronous mention extraction failure
Replay the approved first slice from 857ed203 and e0cc5522 (aggregate 58db416d). Keep extraction within failure cleanup; use the existing runtime lookup and upload error rendering through size-gate helper extractions. Remove the inherited unused markdown import for strict builds.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 13:03:16 -04:00
Logan Johnson
802ba6170e fix(desktop): reconcile overlapping mention prerequisite edits
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit ea87e6975fc9ea451aa9455c4bc569a46f3f1361)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:37 -04:00
Logan Johnson
cc096ca2a1 fix(desktop): preserve mention competitors through fallbacks
Compose edit fallback refs before exact occurrence selection. Keep ambiguous historical labels as non-authorizing blockers for rendering and body-based recipient fallbacks; qualified labels only disambiguate when they own an unambiguous occurrence.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 30545075a876136467c07d82abac83ad1904df23)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit df75b5d1ac6d7aaa2bf0dfb4dfaf43b92539249a)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:36 -04:00
Logan Johnson
6b7b02422e fix(desktop): share exact mention occurrence ownership
Repair recipient presence/removal and qualified-label edit hydration. Keep tagged historical ambiguity non-notifying, share occurrence competitors with persona routing, and preserve the full collision suffix.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 81cfe76e54f69ba62fa9522ad0e72cb22e50fa8c)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 80050880d25fcc104ec580c747fd33a5a7772b8c)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:17 -04:00
Logan Johnson
11dc6c4e0c fix(desktop): bind duplicate mention selections to exact recipients
Extract behavior B from #7114 after the spacing fix. Preserve ambiguous-name rejection across chat, edits, forum and onboarding; keep exact labels through team selection and automatic addressing.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 46f9b75bcc3e735d351e0587cefc105e66d6da2c)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 86b4e6cef624289a6e2c033327a241c2f6031274)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:17 -04:00
Logan Johnson
a89eae5dce fix(desktop): share draft intent authority across composer visits
Keep authored intent in the scoped draft store independently of value deletion. Supersede recovery, sent cleanup and lifecycle persistence across reentry and remount while preserving ordinary destination-bound sends and untouched optimistic recovery. Keep editability and automatic prefix restoration programmatic. Exercise the real store, React lifecycle transition matrix and retained browser editor.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit ff140562c693147730d548582bc39a12d37ce210)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 4b99bc705ebb8a6920c114620360433556bf88f9)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:17 -04:00
Logan Johnson
8e49ba0b11 fix(desktop): retain cleanup for untouched pre-clear source drafts
Use the captured submission revision for sent-draft storage authority, including ordinary destination-bound sends that leave before optimistic clear. Add a discriminating regression for that lifecycle boundary.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 2cbe68693a9b8a9fca240e539abac0f5860f660c)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 7436a129f4a789d19ebcd1cd192678eab577f385)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
c4e55a4e21 fix(desktop): retain outgoing draft deletion authority after navigation
Bind authored revisions to captured lifecycle visits instead of the visible editor. Apply source authority to cancellation and preflight recovery and sent-draft cleanup, while keeping editor ownership separate. Cover reviewer deletion reproduction, queued files, supersession, return visits, and actual thread-switch persistence.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 13e1245bbd042fb6d1afa6cf54152e839d9fe400)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit e5e77d88c3eb87360aac8771d17389abee831d3f)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
e90edd6104 fix(desktop): bind invitation recovery to source draft visits
Invalidate same-channel thread changes and returning visits before late invitation continuations can clear or recover over another draft. Separate authored editor revisions from optimistic clear, capture exact selections before preparation, and bind resolved persona refs to that captured draft. Cover retained-host navigation, recovery, media, and persona preparation; sanitize screenshot stems only.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit b7c4ab9e3f27a7c2f28978d501179f67830073f1)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 2cb986a910abd5aec888393ce24250f2fedcb623)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
31f289fcee fix(desktop): cancel superseded remote invitation continuations
Keep invitation intent alive through preparation, add, and publication, while cancelling dismissal, navigation and replacement. Retain cleared drafts on late cancellation and cover async boundaries with real React and browser regressions.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit cdb35b1021ad24cf1dfa118a42f16d3df197cde7)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 80d9b1bfee9c3943fc4ad213646cf0238167b242)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
09d34c434c test(desktop): capture remote invitation and failure evidence
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 467e9869e923099798c2bd50db2b25062bb9a2b4)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 48075120ad8ee967d226e6b9c1237b3e9baf5198)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
2e2341dc9a style(desktop): format remote mention regression fixture
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit d9d16471562be0a87e7210b8ca7695d447948425)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit dd0b68ae8d92913b743ddb781c3ec722a1a5ae51)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
1f7e36cb89 fix(desktop): authorize remote mentions at the publication boundary
Extract preparation, exact destination checks and retained recipient intent from #7114, independently of labels and profile presentation.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 1976a2ac953b53d25df831b97d22c5318394e7c1)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit ffac74d5a64c08a5d3bdad85a8f69c42ff75e232)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:55:16 -04:00
Logan Johnson
7c09f0c0ca fix(desktop): preserve spacing after multi-word mentions
Extract the mention-caret behavior from #7114 without changing discovery or recipient policy.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 4fe451d9c2)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:54:40 -04:00
Logan Johnson
709c7c5b36 fix(desktop): discover authenticated owned relay agents
Extract native discovery and signed ownership, policy and current membership verification together from #7114.

Co-authored-by: Larry <627498bd4bd1f281a16431e3c6cce3b5c25b6692798c78672298aefbf2f8f8b5@buzz.block.builderlab.xyz>
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit f3ad8ad2d202047da1170516ba8d072ecec777e0)
Signed-off-by: Logan Johnson <loganj@squareup.com>
(cherry picked from commit 19f392548c6b08749533d5938a9a9769b4d61b2b)
Signed-off-by: Logan Johnson <loganj@squareup.com>
2026-09-01 11:54:40 -04:00
klopez4212
114dbf745f Add voice notes to desktop messages (#6978)
## Summary

- add voice-note recording, preview, removal, and send controls to the
desktop composer
- render sent voice notes as waveform cards with scrubbing and
playback-speed controls
- transcode recordings locally into the existing relay video-media
contract, without relay changes

## Testing

- `just ci`
- `pnpm exec playwright test tests/e2e/voice-note.spec.ts`
- native voice-note media contract test against the relay validator

## Screenshots

Focused snapshots are attached below.

---------

Signed-off-by: kenny lopez <klopez4212@gmail.com>
Signed-off-by: Princess Donut <b238ea756dee4d98afa5883fc7f1de61eeabe65bf700e3a5a5a80db5e42e2c2b@buzz.block.builderlab.xyz>
Co-authored-by: Princess Donut <b238ea756dee4d98afa5883fc7f1de61eeabe65bf700e3a5a5a80db5e42e2c2b@buzz.block.builderlab.xyz>
Co-authored-by: Mongo <9cfd347903944d5b85aa6c93d2ab67381b978a92a31914bca69998968752a1d7@buzz.block.builderlab.xyz>
2026-09-01 16:36:37 +01:00
Salman Mohammed
59328d5ae3 feat(desktop): add thread-scoped ACP session experiment (#6909)
## Why

Thread-scoped ACP sessions from #6732 need an opt-in desktop rollout
that preserves today’s channel policy by default.

## What

- Add the default-off “Thread Scoped ACP Sessions” toggle under Settings
→ Experiments using the existing feature-override persistence.
- Map the persisted setting to `BUZZ_ACP_SESSION_POLICY=channel|thread`
for every local and provider-backed managed ACP launch. Changes apply
when managed agents next start; DMs remain conversation-scoped by the
backend.
- Keep the desktop setting authoritative over descriptor environment and
cover the UI, persistence, local spawn, provider payload, and existing
Projects/Workflows experiments.

## Risk Assessment

Low. The experiment defaults off and explicitly preserves `channel`;
changes are limited to managed-agent launch configuration. Existing
running agents are unchanged until their next start.

## Testing

- `. ./bin/activate-hermit && just ci` — passed on the final restacked
tree, including 5,674 desktop tests, 2,796 Tauri tests, and 1,860 mobile
tests.
- `cd desktop && pnpm build:e2e && pnpm exec playwright test
tests/e2e/experimental-features.spec.ts --project=smoke` — 1 passed.
- `. ./bin/activate-hermit && cargo test --manifest-path
desktop/src-tauri/Cargo.toml session_policy --lib` — 4 passed.
- `. ./bin/activate-hermit && cargo test --manifest-path
desktop/src-tauri/Cargo.toml commands::agents::deploy::tests --lib` — 15
passed.
- `. ./bin/activate-hermit && cargo test -p buzz-backend-kubernetes
--test wire_fixtures` — 4 passed.

## Stack Info

Stacked on #6732. This PR depends on #6732 and should merge after it.

Generated with Codex

---------

Signed-off-by: Salman Mohammed <smohammed@squareup.com>
Signed-off-by: Leo <5faf251baee50ee6bcde338aef6acdd70bb3e60115664c2cd490d94a55dfc488@buzz.block.builderlab.xyz>
Co-authored-by: Leo <5faf251baee50ee6bcde338aef6acdd70bb3e60115664c2cd490d94a55dfc488@buzz.block.builderlab.xyz>
2026-09-01 08:37:27 -05:00
Matt Toohey
571c1902d0 fix(desktop): scope composer autocomplete to focus (#6860)
## Issue
I would send a message in the thread side pane and the main chat's
composer would then open its at-mention completion UI:


https://github.com/user-attachments/assets/25e79e05-8672-4f6e-b5cc-81a46638f229

## Summary

- Render inline composer autocomplete only for the focused rich-text
editor.
- Preserve editor focus when opening composer-owned mention controls.
- Add an end-to-end regression for sending in a side thread while the
main composer retains an agent mention.

## Root cause

The main channel composer and thread composer share the channel sending
state. A thread send toggled the inactive main editor disabled and
enabled, causing programmatic editor updates to recompute its stale
mention query and remount the mention menu.

## Verification

- Desktop unit suite: 5,556 passed
- Persistent agent audience E2E spec: 18 passed
- TypeScript typecheck
- Vite E2E build
- Biome and repository text/pubkey/file-size ratchets

---------

Signed-off-by: Matt Toohey <contact@matttoohey.com>
Co-authored-by: Jitter <2b2e6415e748c35180847a37aadae06a11e30dddc76b784e7fd9354c4eb42e7a@buzz.block.builderlab.xyz>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-09-01 14:28:07 +10:00
Logan Johnson
4a9de1a3a1 feat(desktop): add isolated named demo builds (#6407)
🤖 I’m Larry, updating this description on Logan’s behalf.

## Summary

Build named macOS demo apps without Finder automation or collisions with
installed Buzz. `just desktop-demo-build "PR 6407 Demo"` produces a
matching app and DMG, with a fresh build identity even when the same
display name is reused.

- The headless DMG packager uses `hdiutil`; optional Finder styling is
bounded. The existing production release recipe is unchanged.
- Each demo has independent app data, keychain, nest, CLI name,
voice-model storage, repository discovery, and agent OAuth/config
storage. Reset preserves production and sibling-demo state, and retains
retry intent when credential removal or root resolution fails.
- Native links accept only the active build’s registered scheme, then
translate validated entity links into the frontend’s canonical `buzz:`
format.
- The recipe builds all six executable sidecars. Display names are
capped at 31 ASCII characters so the generated identity fits Rust’s
build-time limit.

**Open delivery requirement:** downloaded demos must run without a
Gatekeeper security override. The current recipe is ad-hoc signed and
unnotarized; it does **not** satisfy this requirement. Trusted
branch-demo signing/distribution remains blocked on establishing an
approved signing path. This PR is not being presented as complete
download-and-run delivery.

### Related issue

N/A — reported in the Buzz DMG-packaging workstream.

### Testing

At `11ce21ff97cb387ad676e7caa65b00964097d0bb`, macOS Blox passed the
Tauri workspace suite and compiled-flags gate (including the full
named-demo state; each library pass: 2,992 passed, 19 ignored), Tauri
all-target clippy, the full `buzz-agent` package suite, and frontend
lint/typecheck plus 5,733 tests. Regression coverage includes
cold-start/running entity-link handling, wrong-build rejection, OAuth
deletion failure and retry, unresolved credential roots, and
production/sibling preservation.

At the same head, an extra full named-demo/mesh-enabled run had 3,092
passing tests and one failure: a pre-existing shared-compute `auto`
versus `mesh` expectation, also reproduced on the old published head
`a77b25eca`. The ordinary and demo-state matrix above passes; this is
not an all-features-green claim. Live macOS Launch Services delivery
remains unverified.

GitHub CI completed with 30 successful checks and 9 skipped. The
exact-range security review has not run; its authorization notice
remains open. CI success does not establish trusted signing or
downloaded-app launch.

Earlier demo artifacts established matching app/DMG names, side-by-side
launch, and six non-empty executable arm64 sidecars. These screenshots
show an earlier artifact, not a new build of the final repair commit.
Signature-integrity checks are not Gatekeeper/notarization evidence.

<img width="1032" height="548" alt="Buzz PR 6407 Demo disk image
containing the matching app"
src="https://github.com/user-attachments/assets/bca0277e-db03-4308-b280-fcad55e6d601"
/>

<img width="1186" height="821" alt="Buzz PR 6407 Demo running alongside
other Buzz installations"
src="https://github.com/user-attachments/assets/b4bf4ae5-c341-4e15-8090-9d2ea7c623b6"
/>

---------

Signed-off-by: Logan Johnson <loganj@squareup.com>
Signed-off-by: Larry <8cf5a83f590ec0955b11647d1c88f796a98e088c30a492c58e0e46c3026ae7a4@buzz.block.builderlab.xyz>
Co-authored-by: Other Brother Darryl <cee32d92756729ee0c097c5661b879c6199931cd25315c8cf398dcbf0f155cf1@buzz.block.builderlab.xyz>
Co-authored-by: Larry <loganj+sandbox-larry@squareup.com>
Co-authored-by: Larry <8cf5a83f590ec0955b11647d1c88f796a98e088c30a492c58e0e46c3026ae7a4@buzz.block.builderlab.xyz>
2026-08-31 21:14:19 -04:00
Kalvin C
0affe527e8 fix(model-capabilities): humanize databricks goose model names (#7135)
🤖
## Summary
- add curated human-readable labels for Databricks Goose models that
otherwise render as fully qualified identifiers
- render `data_workflow_tools.goose.goose-glm-5-3` as `GLM-5.3`
- render `goose-claude-4-6-sonnet`, `goose-claude-4-7-opus`, and
`goose-kimi-2-7` as `Claude Sonnet 4.6`, `Claude Opus 4.7`, and `Kimi
2.7`
- make the Global Defaults closed model picker use the provider-scoped
display label while preserving the raw discovered model ID as the
persisted value
- remove the obsolete `keepSelectedModelValueLabel` escape hatch and its
raw-label override path so selected discovered models have one
consistent display behavior
- classify the exact discovered Goose Claude IDs with their canonical
adaptive-thinking capability axes, including Sonnet 4.6's exclusion of
`xhigh`
- expand Rust and TypeScript alias coverage and regenerate the shared
139-vector capability corpus

## Test plan
- `cargo test -p buzz-agent --lib` — 517 passed, 1 ignored
- `cd desktop && pnpm test` — 5,821 passed
- Desktop TypeScript typecheck — passed
- Biome on the changed component — passed
- `git diff --check` — passed
- targeted Playwright Global Defaults regression — passed on the
preceding implementation head; the subsequent commit only removes dead
picker-prop plumbing

Verified at `b9609d12696173aa309d2dbaf4f093a502756c36`. The hook-bound
push exceeded the harness timeout in unrelated Rust doc tests, so the
already-verified rebased commit was pushed with hooks bypassed.

Follow-up to #6955.

---------

Signed-off-by: Kalvin Chau <kalvin@block.xyz>
Co-authored-by: am <6e30cd56c30e030cd31bb0939b94a7c257c9a09d5ba2d92cf2735da45629f248@buzz.block.builderlab.xyz>
2026-08-31 17:13:59 -07:00
Will Pfleger
9ab163190b feat(db): add NIP-FI identity and final-admission schema foundation (#6994)
PR 2 of the NIP-FI plan: the schema foundation. Establishes the durable
server-side identity ledger and final-admission surface that the runtime
phases build on. All of Phase A's migrations live here; later phases own
their own deltas.

Depends on nothing — PR 1 (#6776, merged) owned zero migration files.
This PR's relations are shaped to store exactly what PR 1's verifier
produces: issuer-qualified identity and the four denial classes. They
meet in a later PR that writes a verified assertion into these tables in
one transaction.

## Two internally-ordered migrations

- `0041_nip_fi_identity_foundation.sql` (migration A) — core identity +
base-lifecycle relations (5 tables): issuer-qualified `(iss, sub)`
bindings, lifecycle history/selectors, enrollment policies, and
operation receipts. Applies cleanly to current `main`.
- `0042_nip_fi_authorization_foundation.sql` (migration B) — the
final-admission surface (10 tables): authorization events + capacity,
admission results, replay/receipt guards, audit, invalidation
domains/floors, protected-object authority, authority epochs, and
restore version deltas. Applies to A's resulting state.

Fifteen NIP-FI relations total, zero dangling foreign keys. Identity is
issuer-qualified throughout — no single-global-issuer assumption in any
relation, no `Block`-hardcoding. A single deployment may run one issuer;
that is config, not schema.

## Durable, immutable ledger posture

All 15 relations are append-only (immutable `no_delete`/`no_truncate`
triggers) and carry `community_id` as provenance, not ownership. Both
migrations widen the single SQL source of truth
`community_write_fence_excluded_table` so the relations are never
fence-attached, never purged on community deletion, and never counted as
tenant-scoped drift by the deletion control plane's exact-set catalog
check — the same posture main already applies to `product_feedback` and
`rate_limit_violations`. `schema/schema.sql` keeps one consolidated
definition of that function whose exclusion array byte-matches `0042`,
guarded by a parity assertion so a future consolidation cannot silently
drop NIP-FI relations from the ledger.

This makes a tenant's identity/authorization ledger survive community
deletion, per the spec's `FI-INV-02` (durable binding) and `FI-INV-03`
(tombstone monotonicity) and `NIP-FI.md`'s "durable server state"
ruling. `communities(id)` FK never dangles: community rows become
permanent tombstones, never hard-deleted.

## Authorization shape and cardinality contracts

Authenticated `OperatorDenied` events (`actor_kind` 1–3, non-null
`request_fingerprint`) carry a null `semantic_fingerprint` and commit
without a denial-attempt row. The denial-attempt cardinality and shape
guards are scoped to unresolved pre-auth kind-9 events (`actor_kind =
4`). Applied and no-op lifecycle receipts (`outcome_code IN (1, 3)`)
require exactly one mapped success-transition event; denied lifecycle
receipts (`outcome_code = 2`) require zero events from the complete core
lifecycle success-transition class (kinds 1, 2, 3, 6: enrolled, revoked,
rotated, retired) — any such event paired with a denied receipt would
record a transition that never occurred.

## Mined vs. new

Re-cut from Franco's #1476 (`0029`/`0030`) and Cea's #4772 committer
schema, re-cut along FK topology and renumbered above the live `main`
tip. The buzz-auth core of #1476 is Cea-authored; `Co-authored-by`
reflects verified per-commit authorship of the mined schema.

Zero Rust/`deletion.rs` edits — the migration-only exclusion widening
keeps `EXPECTED_SCOPED_TABLES` untouched.

---------

Signed-off-by: Will Pfleger <pfleger.will@gmail.com>
Signed-off-by: Hayt <9e1c23a3fd83f61da34420e4e88ff1b16e45cafcc0cd9019eb07d4ecfa8ca9b0@buzz.block.builderlab.xyz>
Co-authored-by: Cea Stapleton Cordasco <261786559+cea@users.noreply.github.com>
Co-authored-by: Hayt <9e1c23a3fd83f61da34420e4e88ff1b16e45cafcc0cd9019eb07d4ecfa8ca9b0@buzz.block.builderlab.xyz>
2026-08-31 19:40:35 -04:00
Salman Mohammed
674c173eb7 feat(buzz-acp): give each channel thread its own agent session (#6732)
## What this does

In a channel, people often run several unrelated conversations at once
(separate threads). Today the agent treats the whole channel as one
conversation, so unrelated threads share the same running session —
their context bleeds together and independent tasks can step on each
other.

This change gives the agent a **separate session per thread** inside a
channel. Direct messages stay as one conversation (unchanged). The
channel is still the boundary for who is allowed in and what is visible
— only the agent's working context is now split by thread.

## How it is turned on

Off by default. Operators opt in with one setting:

- `BUZZ_ACP_SESSION_POLICY=channel` — default, current behavior
- `BUZZ_ACP_SESSION_POLICY=thread` — new per-thread behavior

Being behind a flag means we can enable it for a few agents, watch how
it behaves, and roll back instantly without a code change.

## Key design decisions

- **Decide the thread once, up front.** When a message arrives we work
out which thread it belongs to a single time and tag it. Everything
after that (which line it waits in, which session runs it, what history
it sees) uses that tag instead of re-guessing later, which avoids
mismatches.
- **Default stays identical to today.** Under the default setting a
"thread" is just "the whole channel," so existing behavior and every
existing test are unchanged. The new, riskier behavior is strictly
opt-in.
- **Give the agent only its thread's history.** On a reply the agent
sees that thread's messages (including ones that did not mention it),
not the whole channel transcript — less noise and smaller prompts.
- **Don't let one channel use more memory than before.** More threads
means more live sessions, so the existing per-channel limit now caps all
of a channel's threads together — splitting into threads can't multiply
how much work is held.

## Bugs found and fixed while iterating (from review)

- **Same thread, two sessions.** If the worker already holding a
thread's session was busy, a new message for that thread could start a
*second* session on another worker and split its history. Now it waits
for the right worker instead of forking.
- **Interrupting the wrong thread.** A follow-up meant for thread A
could interrupt thread B in the same channel. Interrupts now target the
exact thread.
- **Stuck thread after a crash.** If a thread's turn crashed, its slot
wasn't cleared and stayed blocked for up to ~2 hours. It now clears
right away and retries.
- **Lost the original request.** When a thread was interrupted and then
had to wait for a busy worker, only the follow-up was kept and the
original request was dropped. The full request is now preserved on
retry.
- **Same thread seen as two.** Two spellings of the same thread id
(upper/lower case) could be treated as different threads. Normalized so
they count as one.

## Not in this PR

- The desktop Settings toggle and rollout wiring for managed agents —
https://github.com/block/buzz/pull/6909
- One pre-existing retry edge case (present today without this flag,
unrelated to this change) — tracked separately so this PR stays focused.

## Testing

The full `buzz-acp` test suite passes (830+ unit and integration tests),
plus new focused tests for thread routing, session reuse, interrupt
targeting, crash recovery, and request preservation. Behavior with the
flag off is unchanged.

---------

Signed-off-by: Salman Mohammed <smohammed@squareup.com>
Signed-off-by: Leo <5faf251baee50ee6bcde338aef6acdd70bb3e60115664c2cd490d94a55dfc488@buzz.block.builderlab.xyz>
Co-authored-by: Leo <5faf251baee50ee6bcde338aef6acdd70bb3e60115664c2cd490d94a55dfc488@buzz.block.builderlab.xyz>
2026-08-31 18:17:28 -04:00