fix(imessage): self-explaining private-API failures and dedicated send timeout#91041
Conversation
|
Codex review: needs real behavior proof before merge. Reviewed June 7, 2026, 5:04 PM ET / 21:04 UTC. Summary PR surface: Source +28, Tests +46. Total +74 across 7 files. Reproducibility: unclear. The review failed before ClawSweeper could establish a reproduction path. Review metrics: none identified. Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Risk before merge
Maintainer options:
Next step before merge
Review detailsBest possible solution: Retry the Codex review after fixing the execution failure. Do we have a high-confidence way to reproduce the issue? Unclear. The review failed before ClawSweeper could establish a reproduction path. Is this the best way to solve the issue? Unclear. Retry the review first so ClawSweeper can evaluate the actual issue and fix direction. AGENTS.md: unclear because the file could not be read completely. Codex review notes: model gpt-5.5, reasoning high; reviewed against 3b6bcbfb5045. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +28, Tests +46. Total +74 across 7 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
|
This comment has been minimized.
This comment has been minimized.
|
@clawsweeper re-review Added the missing dependency-layer proof from your review:
The local host is healthy ( |
|
🦞🧹 I asked ClawSweeper to review this item again. |
|
@clawsweeper re-review Updated this PR body with the latest companion imsg state:
No OpenClaw code changes were needed after the latest review; the remaining gap is still live delayed-send or blocked-action proof. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
Live behavior proof — statusMessage on a blocked private-API actionBeyond the unit tests, here is the statusMessage change demonstrated end-to-end against a real bridge-down imsg. Environment: OpenClaw built from this PR (2026.6.1 + this commit, Command (real CLI dispatch, no mocks): Result — the blocked-action error now carries imsg's own status message: The The 150s send-timeout half stays unit-asserted ( |
|
@clawsweeper re-review The live proof gap changed after the prior re-review started. I updated the PR body to include the new macOS 26.5.1 VM proof from #91041 (comment). What the new proof covers:
The remaining timeout tradeoff is still explicit in the body: send-style private API bridge actions may wait up to 150s, and the companion imsg PR is open at openclaw/imsg#139 with green CI. |
|
🦞👀 Command router queued. I will update this comment with the next step. Re-review progress:
|
7175ea0 to
82f8eeb
Compare
82f8eeb to
f6338db
Compare
|
Maintainer proof waiver + merge rationale Recording a maintainer waiver on the delayed-send proof gate, with the dependency behavior verified directly against imsg source. Why a waiver: the delayed-send timeout targets the 60–124s macOS 26 stuck-send tail, which can't be reproduced on demand — it's inherently source/unit-provable, not live-reproducible. The blocked-action Verified no-regression (read Availability tradeoff (accepted): the only new behavior shipping ahead of #139 is that a fully wedged imsg RPC (no reply at all, not merely a slow send) would hold the send path up to 150s instead of 10s. Rare, and worth the macOS 26 send-reliability and diagnostics gains. Dependency state: openclaw/imsg#139 is green + mergeable but lives in an upstream repo I don't own; it merges/releases on its own schedule. The timeout half activates automatically when it ships — no further OpenClaw change needed. Checks: rebased onto latest Landing as the partial mitigation (diagnostics now, timeout latent until #139 releases). @clawsweeper re-review |
|
🦞👀 Command router queued. I will update this comment with the next step. Re-review progress:
|
|
@clawsweeper re-review (Prior re-review run was cancelled mid-flight, not a review failure. Maintainer waiver + verified no-regression rationale already recorded above; head is f6338db, all checks green.) |
|
🦞👀 Command router queued. I will update this comment with the next step. Re-review progress:
|
…d timeout (openclaw#91041) Append imsg's own status message (SIP / library validation / macOS 26 AMFI gate) to iMessage private-API blocked-action errors so operators see the real blocker instead of a generic "run imsg launch". Add a dedicated 150s default timeout for iMessage send RPCs (explicit opts and probeTimeoutMs still win) so macOS 26 bridge stalls are not aborted mid-send. Staged mitigation: the longer wait fully activates once the companion bridge timeout (openclaw/imsg#139) ships; on current imsg the bridge still returns at its own 10s, so there is no regression. Diagnostics half is live-proven; the delayed-send timeout is covered by source + unit proof + maintainer waiver.
…d timeout (openclaw#91041) Append imsg's own status message (SIP / library validation / macOS 26 AMFI gate) to iMessage private-API blocked-action errors so operators see the real blocker instead of a generic "run imsg launch". Add a dedicated 150s default timeout for iMessage send RPCs (explicit opts and probeTimeoutMs still win) so macOS 26 bridge stalls are not aborted mid-send. Staged mitigation: the longer wait fully activates once the companion bridge timeout (openclaw/imsg#139) ships; on current imsg the bridge still returns at its own 10s, so there is no regression. Diagnostics half is live-proven; the delayed-send timeout is covered by source + unit proof + maintainer waiver.
Summary
Two macOS-26-resilience fixes for the iMessage channel:
Surface why the private API is unavailable. The probe now carries imsg's own
status --jsonmessage(SIP / library validation / macOS 26 AMFI gate) intoIMessagePrivateApiStatus.statusMessage, and blocked actions append it. Operators on macOS 26.5 stop getting the misleading "run imsg launch" with no reason.Decouple the send timeout from the probe timeout. Sends inherited the 10s probe default via
client.request. On macOS 26 the private-API bridge intermittently stalls up to ~124s; the 10s abort dropped attachment/reply sends (non-recoverable shapes). NewDEFAULT_IMESSAGE_SEND_TIMEOUT_MS = 150_000for sends only (covers the observed upper bound + headroom); probes/health checks stay fast. No new config surface — explicit opts/probeTimeoutMsstill win. Mirrors the BlueBubbles send-timeout fix (fix(bluebubbles): configurable sendTimeoutMs, bump send default to 30s #69193).Companion imsg bridge fix. ClawSweeper correctly found that OpenClaw's 150s client wait was incomplete while upstream
imsgbridge sends still defaulted to 10s. Companion PR open: fix: use longer bridge timeout for send actions imsg#139 at4c85d165c31f4711f75d7bfda4c31723219ebaddchanges send-style bridge actions (send-message,send-multipart,send-attachment,send-poll,send-reaction) to use a 150s bridge response timeout while keeping non-send RPC waits at 10s and preserving explicit timeout overrides.send-reactionis included because tapbacks build anIMMessageand dispatch throughsendMessage:;notify-anywaysintentionally stays at 10s because it is a message-item mutation path.Verification
pnpm tsgo:extensionsclean.node scripts/run-vitest.mjs extensions/imessage/src/status.test.ts extensions/imessage/src/actions.test.ts extensions/imessage/src/send.test.ts(3 files, 81 tests passed).$autoreviewclean (it caught an initial 60s-too-short default vs the documented 124s stall window; fixed to 150s).IMsgBridgeProtocol.defaultResponseTimeout = 10.0, andRPCServer/ CLI bridge send paths calledIMsgBridgeClient.shared.invokewithout a longer send timeout. Companion fix: use longer bridge timeout for send actions imsg#139 fixes that dependency-layer timeout contract.4c85d165c31f4711f75d7bfda4c31723219ebadd):swift format lint Sources/IMsgCore/IMsgBridgeProtocol.swift Tests/IMsgCoreTests/IMsgBridgeProtocolTests.swiftDEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer swift test --filter IMsgBridgeProtocolTests(7 tests passed)DEVELOPER_DIR=/Applications/Xcode.app/Contents/Developer make test(325 tests in 2 suites passed)macosandlinux-read-corepassedimsg status --jsonreturnedmessage: "Connected to Messages.app. IMCore features available.",v2_ready: true, andbridge_version: 2;pnpm openclaw channels status --probe imessage --jsonreported iMessage configured/running withprobe.ok: trueandprivateApi.available: true.openclaw message react --channel imessage ...dispatch returned the blocked-action error with imsg's own reason appended:imsg reports: SIP is disabled and the helper dylib is present, but Messages.app is not currently injected. Run \imsg launch` to enable advanced IMCore features.` See the proof comment: fix(imessage): self-explaining private-API failures and dedicated send timeout #91041 (comment)🤖 Generated with Claude Code