fix(plugin-sdk): failed raw channel sends report success#109906
Conversation
|
Codex review: needs maintainer review before merge. Reviewed July 18, 2026, 6:24 AM ET / 10:24 UTC. Summary PR surface: Source +33, Tests +13. Total +46 across 4 files. Reproducibility: yes. from source and the supplied live provider transcript: the pre-fix raw adapter forwarded Review metrics: none identified. Stored data model Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Risk before merge
Maintainer options:
Next step before merge
Maintainer decision needed
Security Review detailsBest possible solution: Keep failed raw provider results as adapter-level exceptions, retain Do we have a high-confidence way to reproduce the issue? Yes, from source and the supplied live provider transcript: the pre-fix raw adapter forwarded Is this the best way to solve the issue? Yes, conditionally: moving the throw into the non-exported raw-adapter boundary fixes the incorrect delivery classification without changing the exported direct normalization helper’s contract. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 2e21d53c84ec. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +33, Tests +13. Total +46 across 4 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
Review history (6 earlier review cycles)
|
|
Addressed the compatibility finding:
@clawsweeper re-review |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Co-authored-by: 杨浩宇0668001029 <[email protected]>
…emoved fs dependency) (openclaw#110589)
|
Merged via squash.
|
…9906) * fix(plugin-sdk): reject failed raw channel sends * fix(plugin-sdk): preserve raw result helper compatibility * test(plugin-sdk): cover raw send fallback errors Co-authored-by: 杨浩宇0668001029 <[email protected]> * fix(security): bound skill-file audit read via safe reader (restore removed fs dependency) (openclaw#110589) --------- Co-authored-by: Peter Steinberger <[email protected]>
What Problem This Solves
Fixes an issue where plugins using the legacy raw channel send adapter could report a failed provider delivery as successfully sent when the provider returned
ok: false.Why This Change Was Made
The outbound adapter contract treats a resolved result as a successful delivery, while the legacy raw adapter forwarded an object that carried
ok: false. The adapter boundary now throws the provider error before delegating to the exported normalization helper. This matches the documented Plugin SDK migration contract while preserving the helper's existing direct-call behavior and public API.User Impact
Failed legacy plugin sends now reach the normal outbound failure path instead of being counted and surfaced as successful deliveries.
Evidence
src/plugin-sdk/channel-send-result.test.ts, 6/6 passed, including the provider-error fallback case added during review: https://github.com/openclaw/openclaw/actions/runs/29638389495ntfy.sh): a publish to a random temporary topic returned HTTP 200 with message idF52yv796UlWT, and polling that topic observed the same random marker.ntfy.sh): the provider rejected an invalid priority with HTTP 400 andinvalid priority parameter. On currentorigin/main(b2e34b03b5), the legacy adapter incorrectly resolved{ ok: false }; with this patch, the same provider rejection rejects withntfy HTTP 400: invalid priority parameter.pnpm plugin-sdk:surface:checkpasses.scripts/check-changed.mjspassed conflict-marker, max-lines, attribution, wildcard export, duplicate coverage, dependency pin, and formatting checks. Its Plugin SDK API baseline lane fails identically on a clean currentorigin/maincontrol, so no baseline file is changed here.