Skip to content

feat(host): release opted-in attachments after confirmed sends - #2336

Merged
zrmarley merged 11 commits into
mainfrom
zmarley/host-delete-after-send
Nov 18, 2026
Merged

zrmarley merged 11 commits into
mainfrom
zmarley/host-delete-after-send

Conversation

@zrmarley

@zrmarley zrmarley commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

What changed

Add default-off, best-effort release of temporary managed attachment sources after a natively confirmed post.

  • Opt in with host.saveBytes(bytes, {sha256, releaseAfterSend: true}). Native must acknowledge releaseAfterSend === true. Missing acknowledgement means an older host may have saved without consent: possibly saved, do not retry.
  • Native records bounded, process-local consent for the exact private file and saving human Nostr owner. Final consent is fenced against identity close and native command timeout/drop. Renderer disposal or a lost reply is not native cancellation.
  • Shared attachment tools pass snapshot/upload-matching hints outside signed events through existing app-client/runner/native owners. Hints alone grant no deletion authority; standalone clients gain no deletion implementation.
  • “Sent” means the relay accepted the exact signed event ID, after the complete native evidence wrapper succeeds. It does not mean recipient delivery/read, permanent remote storage, or local deletion.
  • Only then does native detach best-effort release on its app runtime and immediately return the confirmed event, allowing the send tool to return sent and the runner to leave sending without waiting for cleanup. Release checks consent, owner, direct-child path, saving-plugin suffix, private no-link metadata, file identity, content hash/size and matching confirmed imeta.

No new dependency, grant, IPC command, durable service, timer, sidecar, consumer enablement or FOUNDATION entry-point change. The November 14 reconciliation merges main 4a87b5cc135453bc9f461ed5dfed3f6d8692f7ea into the existing branch without rewriting accepted history; prior reviews and runtime evidence remain scoped to their snapshots.

Best-effort semantics and limits

One message shares one 30-second cleanup-entry budget, captured before spawning and including scheduling/queue wait, using existing byte admission/root ownership and app-wide reader exclusion. The confirmed send does not wait for cleanup. Cleanup refusal/error never turns that result into an error or repost. Already-dispatched blocking I/O keeps its actual-work byte/root/reader guards through completion and may outlive the budget with an unknown deletion outcome.

Detached cleanup belongs to the native app runtime, not the runner: runner disposal does not cancel it. App shutdown need not drain cleanup. Undispatched work may be lost and sources retained; dispatched unlink may complete with unknown outcome. No durable work or guarantee of outliving the app.

Cleanup is not eventual erasure. Restart loses consent; refusals can retain sources indefinitely. Expiry only permits removal during a later-save sweep. Keep the posted link for reuse rather than reading a released path again. New app-wide reads promptly refuse while cleanup holds exclusion.

The app's read/upload mapping is trusted, not independent cryptographic lineage. Media transformations/hash mismatches safely omit cleanup. Windows keeps sources because safe platform file identity is unavailable. Windows was not executed or cross-compiled locally: only aarch64-apple-darwin is installed. The hosted Windows lane is manual-only and was skipped; it is not Windows-green evidence. Non-Unix confirmed-send retention coverage is present, and Unix-only unlink/hash success tests are gated accordingly. Production identity checks are unchanged.

Consumer opt-in remains separate, after a compatible released frontend/native pair and acceptance.

Validation and review

Current reconciliation candidate: af030bb, merging previous published 54a1610 with main 4a87b5c. The native attachment smoke below is historical combined-candidate evidence, not a run on this head. Current hosted checks are green after the controlled rerun below; maintainer approval remains a separate gate.

November 14 reconciliation

  • Preserve upstream self-mention refusal after attachment/body/mention resolution and before the existing single publication/hints branch. Earlier uploads may already exist; refusal does not publish or invoke confirmed-post cleanup. No upload rollback is claimed.
  • Preserve both sides' tests; add send/subthread attachment-bearing self-mention regressions. Ordinary attachment sends retain their matching out-of-band hints.
  • All other feature additions/deletions against the new main are unchanged, including local-only cleanup hints, protection/lifetime admission, exact native confirmation and best-effort release. No new native campaign or live file operation.
  • Independent integration-delta review: PASS, 9/10 on exact af030bbc; no blockers or optional changes. This checks the reconciliation, not a new full-feature/native acceptance campaign.
  • Complete root Vitest on exact af030bbc: 1,102 files passed / 8 skipped; 22,019 tests passed / 26 skipped, 1,251.68s, with no failed tests/files. Includes tools (183 cases), app-client (32), Codex runtime (249), Claude execution (10), and agent service (595, including its existing skip). The outer supervisor timed out at 900s but the original suite continued to a complete successful JSON report; completion was separately verified with unchanged HEAD/clean tracked tree and no surviving test processes. No duplicate full suite was launched.
  • Normal non-force push passed all mandatory hooks: TypeScript/related unit tests 219.21s, design types/guards 7.87s, locked workspace all-target Clippy 41.56s, and destination/history policies. No bypass, assertion/deadline changes or source changes after independent review. Full diff/whitespace, merge parents, DCO/coauthor trailers, and excluded local fixture hashes were rechecked.
  • Published remote and PR head verified as exact af030bbc. GitHub reports MERGEABLE, with REVIEW_REQUIRED. Current checks are 63 successes, 1 skipped (Windows), none pending or failed, after CI run 43616744045, attempt 2 completed successfully at 2026-11-14 22:27 UTC. WebKit journeys 11/18, Vitest flake-check 2/2 and the required aggregate all passed; DCO Check succeeded. This was one controlled failed-jobs rerun at unchanged head after source/log assessment, with no code or assertion changes. Current CI is green; the intermittent failure cause is not established or claimed fixed. Maintainer approval, merge, release and consumer enablement remain separate.
  • Original attempt 1 remains part of the evidence: 60 successes, 3 failures, 1 skipped (Windows), including WebKit journeys 11/18, Vitest flake-check 2/2 and their required aggregate. Its failure details follow; the later pass does not erase them.
  • WebKit failed nested-replies.spec.mjs:975 (crowded capped branches, width 1024): toolbar-placement difference 0.0718689px against the unchanged <0.05px assertion. The same assertion already failed at width 1280 on unrelated PR #3534, job evidence, with a 0.110016px difference; that PR changes profile/status UI, not this feature. No tolerance was relaxed or layout code changed here.
  • Vitest flake-check iteration 1/5 failed Codex's stops an in-flight file reader at turn end, including late spawn: true, awaiting the tool reply at runtime.test.ts:609. Iterations 2–5 passed unchanged within that same job. This establishes intermittent behavior on this snapshot, not its cause or absence of a product defect. Source/log assessment found no demonstrated feature-caused defect: the case has no attachments; the reader cancellation and RPC reply owners are unchanged, and the new locality flag is consumed only when forwarding publication options. The failed log lacks intermediate lifecycle events, so Codex is not proven unrelated. The single controlled rerun above passed without a source repair; no root-cause fix is claimed.

Historical readiness head — November 12

The readiness checklist below applies to 8e2f69d, based on 128cd4c, and the combined runtime candidate it names. It is not new-head execution evidence.

Readiness checklist — November 12

buzz-review-completed

  • Independent agent review: replay review PASS (9/10) at ebe1b47, with the test-only signature correction independently verified at exact published 8e2f69d; no remaining recommended source blockers.
  • Agent exercise: the reported native round on combined d3b8f73 saved the ordinary/control pair, confirmed a normal attachment post, observed opted-in source removal and unchanged control, then retrieved/rendered the uploaded GIF. This is existing reported runtime evidence, not a new execution by the readiness reconciler.
  • Human confirmation: the human personally inspected that existing uploaded image and explicitly accepted it as human verification, replacing the proposed duplicate successful human-initiated round. This confirms image visibility, not independent human filesystem observations.
  • Snapshot applicability: d3b8f73 starts at this PR's exact 8e2f69d and adds only the separately reviewed fix(goose): propagate ACP work cancellation to plugin tools #3351 bridge. Rechecked aggregate stable patch ID d7650b01f0514ae96b41836b999f0b2dfd314872 matches the bridge; its ten-file delta changes no native attachment save/release implementation. This combined native workflow is the bounded exercise supporting review readiness, not an isolated-head or whole-product certification. No exercise waiver is claimed for feat(host): release opted-in attachments after confirmed sends #2336.

The remaining platform/release limitations below are disclosed, not represented as completed checks. Maintainer approval, merge, consumer enablement and release remain separate. The disposable attachment fixture and cancellation diagnostic are not included in this PR. No new tests, live calls, app lifecycle changes or source edits were performed for this disposition.

November 11 reconciliation evidence

  • Replayed six accepted commits from ea9260aaa8c7b4fd1cb7c5be8c01624de98f087c, then added one test-only upstream spawn-signature compatibility fix. Conflict resolution preserves upstream cancellation/protection snapshot lifetime, retired-owner-read exclusion and streamed write ordering alongside attachment locality and native release acknowledgement tests.
  • Target-backed Claude/Codex readers keep ordinary remote sends but suppress desktop managed-attachment cleanup hints; no remote deletion was added.
  • Eight complete affected JavaScript test files: 1073 passed / 1 existing skipped at ebe1b47fca8fb87ad486c5ada1690506ed0cbad1; final 8e2f69d changes only one Rust test call to pass the three newly required absent options.
  • Bare-candidate Rust workspace tests compiled after that test compatibility fix, and managed cleanup regressions printed successful results, but the test binary subsequently crashed with signal 11 / SIGSEGV (buzz_foundation_lib-688197a4fbe2a305, last output in window-state tests). The Rust workspace run is NOT green. No test(window-state): separate native preparation from preserve policy #2842 testability seam is stacked here; no unrelated repair is included.
  • Independent replay review PASS, 9/10 at ebe1b47; independent follow-up PASS for 8e2f69d's test-only signature correction. Source review is not live acceptance.
  • Normal hook-protected lease push succeeded: types/related tests 218.98s, design 7.14s, workspace all-target Clippy 118.60s, repository/rewrite policy checks passed. Earlier foreground push hit the runner's 240-second limit before publication; the logged retry reran normal hooks without bypass. The successful Clippy run does not erase the Rust test crash.
  • Exact remote and PR head verified 8e2f69ddbe1be34043dd598192c1f82eda5b20dd; PR is mergeable. That historical published-head hosted checks settled: 63 successful / 1 skipped (Windows), none pending or failing, rechecked November 12; that is separate from the non-green local Rust attempt and historical checks below.

Combined native attachment smoke — bounded acceptance complete

Companion #3351 passes the existing ACP work-cancellation signal through to Goose plugin tools. It was a separate PR against main and has since merged, not a stacked dependency or a change introduced by this PR. Neither implementation depends on the other; the combined candidate was used for the Goose-based native attachment exercise.

The experimental combined candidate d3b8f73a318bb1ae03ad43d371c6d33007ffb974 contains this PR's exact 8e2f69d source plus the companion bridge delta. Native attachment smoke evidence:

  • The agent reported saving distinct temporary source/control files, a confirmed normal core send, subsequent opted-in source absence, and ordinary control retention with unchanged hash.
  • The agent also reported retrieving and rendering the uploaded GIF after source release. Human visual inspection confirmed that existing uploaded image.
  • This completes the bounded combined-candidate attachment smoke: the successful agent round plus human visual inspection replaces a duplicate successful human-initiated round. Source removal/control integrity remain agent-reported observations, not additional human filesystem checks.
  • A separately attempted send was refused with an upload authentication error. No confirmed message resulted, and earlier files may have uploaded before refusal. The underlying cause remains unresolved. This is not a successful send; it is disclosed separately and is not a blocker to the accepted bounded smoke.

This attachment evidence is not acceptance of bare #2336, a packaged-release certification, or an exercise of Stop during a pending Goose plugin call. #3351 records its own separate cancellation/no-revival evidence and readiness disposition; its agent-exercise waiver does not apply here. The disposable smoke plugin is not included in this PR or a shipped product feature. No additional live round is claimed.

Existing regressions cover real temporary filesystem saves/unlinks under MockRuntime and confirmed-post HTTP evidence against a loopback server; JavaScript upload/publication are mocked. The combined native smoke adds one real workflow, not exhaustive platform, failure or lifecycle coverage.

Historical published-head evidence — 1c5a5f4

  • Exact-head CI run 41905253578 SUCCEEDED. Rechecked exact-commit checks and PR rollup: 39 SUCCESS / 2 SKIPPED, with no pending or failed checks. Windows native validation and the unselected browser-flake lane were skipped; these are not platform-acceptance evidence.
  • Local checks at this head: harness kit 18 passed (510ms), locked workspace all-target Clippy passed (11.36s), service full file 444 passed / 1 existing skipped (31.39s), and all six affected JS files 718 passed / 1 existing skipped (36.46s). No new local full-workspace Rust test run is claimed.
  • Normal pre-push hooks passed on the first attempt at this head: types/related unit tests 292.89s, design 6.20s, Clippy 4.87s, and repository/rewrite policy checks. No hook bypass, timeout changes or retries were used for this push.
  • The rebase onto 43747aeb01eb8c6801028ab68b7011e0b8065bcb resolved one additive EOF conflict in src/buzz-mcp/tools.test.ts, retaining the complete main Canvas boundary test and feature attachment tests. Only conflict markers were removed; no assertions, helpers or production behavior were edited. All 21 feature files retain identical ordered added/removed line bytes versus the previous snapshot. The automatic documentation, Canvas, native agent and runner/service merges were checked for preservation of both changes.
  • Frozen range-diff against the previous snapshot 648a518: SHA256 ef6bc32b2921e7359b1c5b340dddd558a5e758f8637a38c2ba4f8dea561000ec. Full feature binary patch from current merge-base: SHA256 3cecfc458dbed6a77e05a27abfca265964dea51de8f3f104729d5b1e6a492be7. DCO/coauthor preserved; worktree clean. No feature dependency/lockfile edits.
  • Historical independent review: Wes's automated COMMENT review, submitted 2026-11-05, reviewed the historical 1c5a5f46 head and found no actionable correctness or security defects. It was source-only: no local tests, builds, app launches or PR code execution. It is a comment, not approval or merge authorization. Its description-snapshot note is addressed here.

Earlier-snapshot evidence — not new runs on the current head

  • At 0ee012bed9f70bde3875c552a41a62fb572f268e, native host_ 131 passed (35.45s) and app_agents 25 passed (1.33s); these filters overlap and are not unique-test totals. These are earlier local native results, not a current-head native rerun.
  • At 1bff02c, independent differential testing reproduced the old-production held-byte response timeout (RED 2.07s) and passed the detached-cleanup implementation (GREEN 0.07s). Kalvin's subsequent COMMENT review on that snapshot reported the confirmed-send delay and harness-only watchdog findings resolved. Async cleanup-attempt return is not actual-work drain; app shutdown need not drain. Atomic RAII admission remains necessary because RwLockReadGuard is !Send across actual-work boundaries.
  • The test follow-up at 09c11e9 removed the redundant JS test-local cleanup model; its teardown note is therefore moot. Existing publication success/failure/uncertainty tests and native host_release_confirmed_send_returns_before_cleanup_byte_admission_and_preserves_evidence remain. The strengthened deadline test requires immediate first-poll Ready after explicit expiry while the byte permit stays held. On that earlier snapshot's test change, a compiling first-poll reset-budget mutant failed in 0.09s; restored production passed in 0.13s. The mutant was not committed. No safety coverage was weakened.
  • Historical refresh at 0ee012bed9f70bde3875c552a41a62fb572f268e stopped on unchanged Profile timeouts and a harness-kit assertion independently reproduced on main. No kit fix was added by this feature; upstream test(agents): refuse a real relay workflow mention in the harness kit #2444 supplied the repair. Earlier service timeouts on that snapshot were retained, and unchanged diagnostic reruns passed. These later passes do not establish that timing failures are eliminated.
  • Historical push at 648a518 initially failed only the unchanged Profile pending/unavailable 5000ms timeouts (5076/5137ms). A subsequent unchanged full-hook retry at lower load passed without test or timeout edits. This is historical evidence, not a failure or retry on current head 1c5a5f46.

The historical native IPC-watchdog failure remains unresolved. During the earlier d182ac5 investigation, one five-second fixture timeout caused 19 poisoned-lock followers; independent repetition passed 20/20 native invocations. A later independent review at ddeabaf passed 3/3 exact-fix-head parallel runs. Those passes neither identify the stalled operation nor prove the failure absent. No production/test timeout was increased or assertions weakened to hide it. Historical unchanged Profile timeouts also remain part of the earlier validation record; later normal hooks passed without test edits.

Remaining platform and release acceptance

The historical automated review is a COMMENT, not maintainer approval. Earlier reviews, CI and runtime evidence apply only to their named snapshots and do not establish the untested surfaces below.

Isolated-PR and packaged-release acceptance, native focus/accessibility and Windows remain unverified. The combined native workflow above includes a real upload and human image inspection, but it does not establish comprehensive packaged desktop/Wry, trusted-HTTPS or platform coverage. The November 11 full-workspace Rust attempt is non-green (SIGSEGV above); historical browser coverage is hosted CI, not a local packaged-app exercise. No browser tests were added or removed; not every race/queue permutation has its own fixture.

Broader future acceptance, if separately authorized, in a safe disposable account/VM: send an opted-in source through direct and process readers; verify only an exact-ID confirmed post releases it on supported platforms, an ordinary sibling remains, and posted media stays usable. Verify upload/unconfirmed-send/active-reader refusal and restart retain sources without automatic retry or consent adoption.

@zrmarley
zrmarley force-pushed the zmarley/host-delete-after-send branch 2 times, most recently from f7562cd to 6aac8f4 Compare November 3, 2026 22:57
@zrmarley
zrmarley marked this pull request as ready for review November 3, 2026 23:40
@zrmarley
zrmarley requested a review from a team as a code owner November 3, 2026 23:40

@kalvinnchau kalvinnchau left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Cleanup can delay delivery of an already-confirmed send result. Native packaged-app acceptance remains unverified.

Comment thread src-tauri/src/app_agents.rs Resolved
@zrmarley
zrmarley marked this pull request as draft November 4, 2026 03:53
@zrmarley
zrmarley marked this pull request as ready for review November 4, 2026 04:44

@kalvinnchau kalvinnchau left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 One nonblocking test-usefulness finding. The prior confirmed-send delay and harness-only watchdog findings are resolved.

Comment thread src/features/agents/service.test.ts Resolved
@zrmarley
zrmarley force-pushed the zmarley/host-delete-after-send branch 2 times, most recently from 648a518 to 1c5a5f4 Compare November 4, 2026 20:17

@wesbillman wesbillman left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Star Lord’s automated source review via Wes’s account, with independent Rocket, Mantis and Groot coverage.

Reviewed head 1c5a5f46a475447d0402890a87bd3158eed617ef, target base 8c3bf75dd50fdbd13fcd98df0fe5adfc41766525 (merge-base 43747aeb01eb8c6801028ab68b7011e0b8065bcb).

No actionable correctness or security defects found in the reviewed change. The prior confirmed-send delay is resolved in source: the full native evidence wrapper confirms the exact event ID before cleanup is detached, so byte admission cannot delay the sent result. Reviewed consent/file matching, command cancellation and identity fencing, actual-work reader exclusion, and the shared cleanup deadline. The redundant test-local cleanup model was removed; source-inspected tests cover real native boundaries, including held byte admission and first-poll deadline expiry.

Optional documentation note: the description’s “Current head” and base still name 648a5186 / e121e527, which differ from the revision above. The linked CI run 41893748047 also belongs to that older head. Refresh those references and bind each validation claim to its actual snapshot; the independent current-head check snapshot below is separate evidence.

Source-only review of pinned Git objects, callers, regression-test source and public PR material; no local tests, builds, app launches or PR code execution. No attached images were present. A one-time hosted-check snapshot at this head reports CI required successful; Windows native validation and the unselected browser-flake lane were skipped. Packaged desktop/Wry, real media-server, native focus/accessibility, Windows and human acceptance remain unverified. Best-effort cleanup is not guaranteed erasure or a remote-storage guarantee. This COMMENT review is not approval or merge authorization.

zrmarley and others added 7 commits November 11, 2026 10:07
Record bounded process-local same-owner consent at managed save, pass snapshot-matching attachment hints outside signed events, and release exact verified sources only after native publication confirmation. Keep cleanup best-effort and preserve confirmed send success.

Co-authored-by: goose <goose@block.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Gate verified-unlink success coverage to Unix, exercise confirmed-send retention on non-Unix, and bound native fixture gate entry with a red-first diagnostic regression. Narrow the explicit-sweep test wording without changing production identity checks.

Co-authored-by: goose <goose@block.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Return the evidence-confirmed exact event before cleanup byte admission. Capture the owned cleanup deadline before spawning on the app runtime, retaining existing actual-work admission and exclusion. Cover held byte admission, runner sending completion, and expired or cancelled cleanup; remove the harness-only watchdog test.

Co-authored-by: goose <goose@block.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Require immediate first-poll completion after cleanup deadline expiry, preserving real permit, file, capacity and cancellation assertions. Remove only the redundant test-local JS cleanup model; existing publication and native held-byte-permit regressions remain.

Co-authored-by: goose <goose@block.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
…te target

Codex and Claude Code bound to a remote execution target read file bytes from
somewhere other than this desktop. Their existing shared app client still
publishes through local native custody, so a path or content that happens to
match a separately consented local managed save could be mistaken for a local
source and conflated with local cleanup. No reproduced exploit, but a
correctness gap in the combined tree.

Add a private `localAttachments?: boolean` option to `appClient`. When false,
publish drops `managedAttachments` hints from the forwarded `PublishOptions`
before calling `AgentHandle.publish`. Lifetime check, startup waits, upload,
publication and other publish options are preserved. The two bundled
plugin-execution call sites pass `localAttachments: !this.target`.

No signed-tag change, IPC schema change, execution-provider API change, new
module, cleanup command or remote deletion is added. Native consent remains
the final authority for any local managed release.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Use matching upload metadata and assert real attachment publication for Codex and Claude execution-target readers. Scope the documented guarantee to those bundled readers while retaining trusted custom-reader compatibility.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Supply absent credential, protected-agent and secret options in the managed-file read-admission regression.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
@zrmarley
zrmarley force-pushed the zmarley/host-delete-after-send branch from 1c5a5f4 to 8e2f69d Compare November 11, 2026 18:24
@zrmarley
zrmarley marked this pull request as ready for review November 12, 2026 13:55
zrmarley added a commit that referenced this pull request Nov 12, 2026
## Summary

Pass Buzz's current ACP work-cancellation signal through to Goose plugin
tools. Previously, the Goose tool client exposed the agent lifetime
rather than the lifetime of the work that owned a call, so a plugin
waiting on `client.signal` could remain live after Stop or work
settlement.

- Keep cancellation in the existing ACP session owner. Steered messages
share a work-burst signal; Stop, eligible final-message settlement,
normal completion, failure and session close abort captured work.
- Forward the captured signal through `ToolServer` and combine it with
the Goose agent lifetime. Calls before session work starts or while idle
receive an aborted signal; retiring the agent also aborts captured
calls. Later work cannot revive an earlier captured signal.
- Preserve the existing current-work publication check and two-argument
`ToolServer` consumers. No upstream Goose change, new plugin,
dependency, timer, retry policy or filesystem cleanup behavior is
introduced.
- Update plugin-author and agent help guidance.

Cancellation is cooperative: plugins must retain the supplied signal,
pass it to cancellable operations and check it before external writes.
It cannot undo a write already sent or guarantee termination of
arbitrary external side effects.

## Tests and review

- Regression tests exercise the existing ACP and Goose runtime paths:
Stop during a held added-tool call, no revival on later work, fresh-call
recovery, idle/pre-session refusal, steers, final-send settlement,
failure, process exit, session close and agent retirement. The optional
signal preserves the existing Mesh consumer.
- Independent source review completed, with the routing-assertion
finding fixed and rechecked. A separate integration-fidelity review
confirmed the combined candidate contains exactly the bridge delta.
- Existing complete ACP/Goose directories plus the Mesh Goose test file
on combined candidate `d3b8f73a318bb1ae03ad43d371c6d33007ffb974`: **381
passed, 11 opt-in live tests skipped**. Its frontend build/typecheck
passed. The separate bridge frontend build/typecheck also passed. These
are recorded checks, not a newly run full suite at this PR head.
- Normal pre-commit hooks passed for the three commits. Normal pre-push
hooks passed at exact head `49091442f7ed3d5da13088b22f6d880328f96ca0`:
types/related tests **30.70s**, design checks **8.73s**, repository
policies passed. The Rust lane selected no Rust inputs; no new Clippy
run is claimed. Hosted checks at this exact head are settled: 63
successful, 1 skipped (Windows native validation), including CI required
and DCO Check; no failing or pending checks.
- An earlier broad Vitest diagnostic ran across a changing working tree:
1070 files passed / 2 failed / 8 skipped; 21046 tests passed / 6 failed
/ 25 skipped. Failures were in unchanged Claude transcript and Codex
shell subprocess tests. No causal link to this bridge is established;
this is neither a green full-suite result nor current-head
certification.

## Companion change and bounded native evidence

Companion: #2336 (temporary managed attachment release). Both PRs target
`main` independently; neither implementation is stacked on the other.
This PR fixes the general Goose work lifecycle, not an
attachment-specific test requirement.

A native attachment smoke used the experimental combined candidate
`d3b8f73a318bb1ae03ad43d371c6d33007ffb974` (#2336 head
`8e2f69ddbe1be34043dd598192c1f82eda5b20dd` plus this bridge). The agent
reported a confirmed normal send, removal of the opted-in source,
retention of the ordinary control with unchanged hash, and
retrieval/rendering of the uploaded GIF. Human visual inspection
confirmed the existing uploaded image. This completes the bounded
combined-candidate attachment smoke; it does **not** validate either
isolated PR or exercise Stop during a pending call.

A separate attempted send was refused with an upload authentication
error. No confirmed message resulted; earlier files may have uploaded
before refusal. Its cause remains unresolved and it is not a successful
send. It is disclosed separately, not treated as a blocker to the
accepted bounded attachment smoke.

## Native cancellation acceptance and readiness

A human completed the guided native Stop/no-revival diagnostic on
combined candidate `d3b8f73a318bb1ae03ad43d371c6d33007ffb974` and
explicitly confirmed a pass. The supplied result shows
`pass-cancelled-no-revival`: live host-signal entry, abort observation,
a distinct fresh live signal for later work, the old signal still
aborted, and release all true; `completionMarker` false. The screenshot
does not itself encode a source SHA; candidate provenance comes from the
recorded launch, not the screenshot. The bridge delta in this candidate
has the same stable patch ID as this PR's delta.

The diagnostic is local acceptance tooling only. None of its plugin
source, manifest or artifacts is included in this PR or shipped by this
change.

**Ready for review.** Independent review and explicit human native
acceptance are complete. The human author explicitly waived the separate
agent-executed native cancellation exercise under readiness checklist
step 2; no separate agent-run native cancellation result is claimed. The
applicable readiness checklist is satisfied with that waiver.

buzz-review-completed

Required maintainer/code-owner approval remains outstanding separately.
No merge, release or consumer enablement is claimed.

No browser journeys were added or removed. Automated regression coverage
is at the ACP/runtime tool-dispatch boundary; the native human
acceptance above supplements it without claiming an isolated-PR native
run.

---------

Signed-off-by: Zach Marley <zmarley@squareup.com>
Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
zrmarley and others added 2 commits November 12, 2026 17:28
Preserve attachment locality filtering alongside native tool-operation admission and retain both sets of service regressions.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
Preserve self-mention refusal before the existing attachment publication branch. Cover attachment-bearing self-mentions for send and subthread replies without changing confirmed-send cleanup.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
@zrmarley
zrmarley requested a review from kalvinnchau November 16, 2026 11:08

@kalvinnchau kalvinnchau left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Please address these three small cleanup items before approval. They reduce duplicated test setup and speculative option handling; they are maintenance requests, not newly identified correctness defects.

Comment thread src/buzz-mcp/app-client.test.ts Resolved
Comment thread src/buzz-mcp/app-client.ts Resolved
Consolidate managed-attachment forwarding coverage while preserving the
no-options call shape, remote suppression, and lifetime checks. Forward only
supported local options and reuse the native policy-save fixture helper.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
@zrmarley

Copy link
Copy Markdown
Contributor Author

🤖 Maintenance update at 458a6f8:

  • Consolidated attachment-forwarding tests while retaining local/default forwarding, remote suppression, no-options call arity, and lifetime coverage.
  • Removed speculative handling/tests for publish options outside the supported contract.
  • Reused the existing native save_policy fixture helper without removing exact-file release/sibling-retention or malformed-header coverage.

The cleanup is three files, +5/-115. Normal push completed with every selected mandatory gate enabled: TypeScript and related tests, design types/guards, workspace Clippy, and machine push-policy checks passed. Pre-commit formatting/lint/policy checks also passed. The successful push used BUZZ_TEST_WORKERS=1; the earlier two-worker hook failed. No test timeout, assertion, selection or retry policy was changed. This does not establish that the underlying timing failure is fixed.

Validation limitations and retained failures

The earlier broad batch exercised the identical source tree now committed in this cleanup. It was not green:

Check Recorded outcome
bin/node --test tests/integration/*.test.mjs 313 passed, 1 failed, 1 skipped. The macOS launcher case failed because its copied fixture omitted scripts/dev-credential-helper.mjs, imported by desktop-dev.mjs. This is a source-based fixture finding, not a matched-baseline result.
Full root Vitest, four workers 21,998 passed, 18 failed, 26 skipped; 7 failed files. All 18 failures were unchanged 5-second test timeouts. Cause/baseline was not established.
bin/cargo test --manifest-path src-tauri/Cargo.toml --locked --offline Exit 101 after SIGSEGV; not a completed package pass. The modified attachment-release test logged success before the crash. Stack inspection identified the onboarding window-state test's MockRuntime/AppKit path; it does not establish baseline behavior or make the package green.
First mandatory related-test hook, two workers 3,639 passed, 1 failed, 16 skipped. App.profile.test.tsx → “drops the retained draft after an accepted departure to another account's unavailable Settings” exceeded its 5-second budget. Other selected gates passed.

The full-root timeout files were browser-host/project-git.test.mjs, src/app/entity-navigation.test.tsx, src/app/navigation.test.tsx, src/bundled/workflows/WorkflowsPage.test.tsx, src/features/drafts-sent/DraftPreview.test.tsx, src/features/relay/thread-window.test.ts, and src/shared/design-system/ui/SidebarNavigation.test.tsx.

A single matched diagnostic ran the complete 24-test App.profile.test.tsx once before cleanup (af030bbc…) and once after (458a6f843…), with identical installed dependencies/tools and the same two-worker setting/default timeouts. Both passed; the implicated case took 2,319ms and 2,245ms respectively. That is non-reproduction in isolated whole-file runs, not proof of an unrelated cause or clearance of the original failure. The later one-worker mandatory hook passed on the unchanged cleanup candidate; the earlier failures remain part of the evidence.

Fresh hosted inspection on this exact head currently exposes only the successful DCO check; no new broad Actions run is listed. Earlier green runs belong to older heads and do not validate this cleanup. The PR remains conflicting and review-required. No merge or readiness/validation claim is made here.

Preserve attachment-custody and gateway-routing tests as separate suites.
Combine Claude execution fixture additions while retaining attachment and
workflow hand-over coverage with their own cleanup boundaries.

Co-authored-by: Dr. Spuxx, the Living Mutagen <dbeea7b641217ab95b3c75e547b999cc044d294afebbf240df7fe90c249de836@feedback.communities.buzz.xyz>
Signed-off-by: Zach Marley <zmarley@squareup.com>
@zrmarley
zrmarley merged commit b6d9cc1 into main Nov 18, 2026
69 checks passed
@zrmarley
zrmarley deleted the zmarley/host-delete-after-send branch November 18, 2026 21:31
joshfriend added a commit that referenced this pull request Nov 18, 2026
…open-external

* origin/main: (86 commits)
  feat(plugins): let link preview cards open other targets (#3749)
  Show when each timer runs next on its Attention row (#3539)
  feat(host): release opted-in attachments after confirmed sends (#2336)
  feat: unify sidebar groups and Solo workspaces (#3791)
  fix(search): complete a filter's highlighted suggestion with Tab (#3737)
  fix(messages): put the caret after a remembered agent mention (#3787)
  fix(messages): link scheme-less hosts such as example.com (#3619)
  fix(messages): show the reply banner's target as prose, not Markdown source (#3788)
  fix(user-status): show status emoji in full in the profile preview (#3819)
  Keep message action toolbars reachable (#3597)
  Forward goose inference to the agent gateway natively (#2916)
  perf(threads): read to the unread frontier in one thread load (#3822)
  fix(messages): keep text selection inside the message history (#3505)
  fix(github): offer Merge when ready while a pull request is not mergeable (#3476)
  fix(github): open Command-clicked panel links in the browser (#3474)
  feat(plugins): let a signed version 2 managed policy install and update plugins automatically (#3775)
  feat(agents): let a channel-level turn hand off into its channel's threads (#3786)
  docs: exempt commit identity metadata from the open-source boundary (#3875)
  fix(agents): wait for the community before checking a workflow mention (#3793)
  feat(emoji): larger emoji and roomier cells in the picker (#3862)
  ...

Signed-off-by: Josh Friend <jfriend@block.xyz>

# Conflicts:
#	src/features/messages/LinkPreviews.test.tsx
#	src/features/messages/LinkPreviews.tsx
joshfriend added a commit that referenced this pull request Nov 18, 2026
…ation-links

* origin/main:
  feat(agents): make search the only way agents search messages (#3752)
  feat(plugins): let link preview cards open other targets (#3749)
  Show when each timer runs next on its Attention row (#3539)
  feat(host): release opted-in attachments after confirmed sends (#2336)

Signed-off-by: Josh Friend <jfriend@block.xyz>

# Conflicts:
#	src/buzz-mcp/tools.test.ts
#	src/buzz-mcp/tools.ts
ljknight added a commit that referenced this pull request Nov 18, 2026
…ent-creation-request

* origin/main: (235 commits)
  feat(agents): make search the only way agents search messages (#3752)
  feat(plugins): let link preview cards open other targets (#3749)
  Show when each timer runs next on its Attention row (#3539)
  feat(host): release opted-in attachments after confirmed sends (#2336)
  feat: unify sidebar groups and Solo workspaces (#3791)
  fix(search): complete a filter's highlighted suggestion with Tab (#3737)
  fix(messages): put the caret after a remembered agent mention (#3787)
  fix(messages): link scheme-less hosts such as example.com (#3619)
  fix(messages): show the reply banner's target as prose, not Markdown source (#3788)
  fix(user-status): show status emoji in full in the profile preview (#3819)
  Keep message action toolbars reachable (#3597)
  Forward goose inference to the agent gateway natively (#2916)
  perf(threads): read to the unread frontier in one thread load (#3822)
  fix(messages): keep text selection inside the message history (#3505)
  fix(github): offer Merge when ready while a pull request is not mergeable (#3476)
  fix(github): open Command-clicked panel links in the browser (#3474)
  feat(plugins): let a signed version 2 managed policy install and update plugins automatically (#3775)
  feat(agents): let a channel-level turn hand off into its channel's threads (#3786)
  docs: exempt commit identity metadata from the open-source boundary (#3875)
  fix(agents): wait for the community before checking a workflow mention (#3793)
  ...

Signed-off-by: Laura Knight <lauraknight@squareup.com>

# Conflicts:
#	docs/plugin-authoring-guide.md
LordMelkor added a commit to LordMelkor/buzz-app that referenced this pull request Nov 18, 2026
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* commit '760746bc115340b63ddca5af9b6167e18bb2160e':
  feat(agents): make search the only way agents search messages (block#3752)
  feat(plugins): let link preview cards open other targets (block#3749)
  Show when each timer runs next on its Attention row (block#3539)
  feat(host): release opted-in attachments after confirmed sends (block#2336)
  feat: unify sidebar groups and Solo workspaces (block#3791)
  fix(search): complete a filter's highlighted suggestion with Tab (block#3737)
  fix(messages): put the caret after a remembered agent mention (block#3787)
  fix(messages): link scheme-less hosts such as example.com (block#3619)
  fix(messages): show the reply banner's target as prose, not Markdown source (block#3788)
  fix(user-status): show status emoji in full in the profile preview (block#3819)
  Keep message action toolbars reachable (block#3597)
  Forward goose inference to the agent gateway natively (block#2916)
  perf(threads): read to the unread frontier in one thread load (block#3822)
  fix(messages): keep text selection inside the message history (block#3505)
  fix(github): offer Merge when ready while a pull request is not mergeable (block#3476)
  fix(github): open Command-clicked panel links in the browser (block#3474)
  feat(plugins): let a signed version 2 managed policy install and update plugins automatically (block#3775)
LordMelkor added a commit to LordMelkor/buzz-app that referenced this pull request Nov 19, 2026
* origin/main: (79 commits)
  Use generic copy for external app authorization (block#3870)
  Show readable skill names on GitHub links (block#3728)
  Put your Bestie's DM right under its New chat row in search (block#3673)
  feat(workflows): show the owner as avatar and name, then the date (block#3792)
  fix(messages): keep the first loaded row's text when an older page lands above it (block#3768)
  Use the server's turn messages and prompt senders in remote history (block#3662)
  feat(agents): make search the only way agents search messages (block#3752)
  feat(plugins): let link preview cards open other targets (block#3749)
  Show when each timer runs next on its Attention row (block#3539)
  feat(host): release opted-in attachments after confirmed sends (block#2336)
  feat: unify sidebar groups and Solo workspaces (block#3791)
  fix(search): complete a filter's highlighted suggestion with Tab (block#3737)
  fix(messages): put the caret after a remembered agent mention (block#3787)
  fix(messages): link scheme-less hosts such as example.com (block#3619)
  fix(messages): show the reply banner's target as prose, not Markdown source (block#3788)
  fix(user-status): show status emoji in full in the profile preview (block#3819)
  Keep message action toolbars reachable (block#3597)
  Forward goose inference to the agent gateway natively (block#2916)
  perf(threads): read to the unread frontier in one thread load (block#3822)
  fix(messages): keep text selection inside the message history (block#3505)
  ...

Signed-off-by: LordMelkor <kray@squareup.com>

# Conflicts:
#	vite.config.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants