Skip to content

feat(channels): externalize iMessage - #117101

Merged
vincentkoc merged 1 commit into
mainfrom
feat/externalize-imessage
Aug 1, 2026
Merged

vincentkoc merged 1 commit into
mainfrom
feat/externalize-imessage

Conversation

@vincentkoc

@vincentkoc vincentkoc commented Jul 31, 2026 •

Copy link
Copy Markdown
Member

What Problem This Solves

iMessage currently ships inside the core OpenClaw package even though the plugin catalog, install bridge, and package runtime can support it as an official external channel. This keeps macOS-only channel code and dependencies in every core install.

Why This Change Was Made

Externalizes iMessage as the official @openclaw/imessage npm and ClawHub plugin while preserving cold-install discovery, setup metadata, persisted bundled-plugin recovery, default enablement, channel ownership, state migration, and doctor contracts.

The core package now excludes dist/extensions/imessage/**; the official external channel catalog remains the source for on-demand installation.

User Impact

Existing iMessage operators keep their configuration and migration path. New installs select iMessage normally and install the official plugin on demand. The plugin still requires a signed-in Mac with imsg; this change does not add a Linux transport or send a real message during validation.

Evidence

{
  "verdict": "PASS",
  "runtimeProofHead": "97c084528de3ec2a182a9bfc8b29a6a45ca0a149",
  "coreOmitted": "dist/extensions/imessage",
  "plugin": "@openclaw/imessage",
  "install": "npm-pack",
  "runtimeInspect": "loaded-external",
  "doctor": "fix-pass",
  "gateway": {
    "platform": "linux",
    "channelEnabled": false,
    "coldStarts": 2,
    "healthz": "live"
  },
  "realMessageSent": false
}

Linux validation proves package omission, exact plugin artifact install, runtime inspection, doctor repair, and two Gateway cold starts with the channel disabled. macOS-specific imsg behavior is covered by the focused iMessage status, setup, state-migration, and doctor-contract tests; no fake transport or real account was used.

Release Sequencing

Maintainer decision: land the package ownership change, then require the selected-plugin npm release preflight for @openclaw/imessage on the merged SHA. The release workflow owns coordinated core/plugin publication; the core release must not ship before the matching official plugin package is available. No package is published by this PR.

@vincentkoc vincentkoc self-assigned this Jul 31, 2026
@vincentkoc
vincentkoc marked this pull request as ready for review July 31, 2026 23:15
@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation channel: imessage Channel integration: imessage gateway Gateway runtime cli CLI command changes scripts Repository scripts size: S maintainer Maintainer-authored PR labels Jul 31, 2026
@vincentkoc

Copy link
Copy Markdown
Member Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

@github-actions github-actions Bot added the dependencies-changed PR changes dependency-related files label Jul 31, 2026
@github-actions

github-actions Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

Dependency Guard

This PR changes dependency-related files. Maintainers should confirm these changes are intentional.

Changed files:

  • extensions/imessage/package.json
  • pnpm-lock.yaml

Maintainer follow-up:

  • Review whether the dependency changes are intentional.
  • Inspect resolved package deltas when lockfiles or workspace dependency policy changes are present.
  • Treat pnpm-lock.yaml and package-lock.json diffs as dependency security-review surfaces.
  • Run pnpm deps:changes:report -- --base-ref origin/main --markdown /tmp/dependency-changes.md --json /tmp/dependency-changes.json locally for detailed release-style evidence.

@github-actions

github-actions Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

Dependency graph changes noted

This PR includes dependency graph changes. The dependency guard is informational because the PR author is a repository admin or a member of @openclaw/openclaw-secops.

  • Current SHA: 97c084528de3ec2a182a9bfc8b29a6a45ca0a149
  • Trusted actor: @vincentkoc
  • Trusted role: pull request author; openclaw-secops

Security review is still recommended before merge when the dependency graph change is intentional.

@vincentkoc
vincentkoc force-pushed the feat/externalize-imessage branch from 64c2dc6 to 23a2252 Compare July 31, 2026 23:20
@vincentkoc
vincentkoc requested a review from a team as a code owner July 31, 2026 23:20
@vincentkoc
vincentkoc force-pushed the feat/externalize-imessage branch from 23a2252 to 97c0845 Compare July 31, 2026 23:24
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. labels Jul 31, 2026
@clawsweeper

clawsweeper Bot commented Jul 31, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 7:50 PM ET / 23:50 UTC.

ClawSweeper review

What this changes

This PR removes iMessage from the core distribution and makes @openclaw/imessage an official externally installed channel plugin, with catalog, packaging, recovery, test, and documentation updates.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

This PR remains necessary: current main still ships iMessage as a private bundled plugin, while the branch converts it to an official external package and preserves recovery through the existing generic relocation bridge. The patch has no concrete correctness or security finding, but it changes the supported upgrade and release boundary, so the protected maintainer review should decide whether to adopt that product direction. Likely related people: Peter Steinberger is the high-confidence routing candidate from the current plugin discovery and iMessage metadata history.

Priority: P2
Reviewed head: 97c084528de3ec2a182a9bfc8b29a6a45ca0a149
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The implementation is coherent with the existing plugin and release architecture, with no actionable patch finding; maintainer product approval remains separate from patch quality.
Proof confidence 🌊 off-meta tidepool Not applicable: This is a MEMBER-authored PR, so the external-contributor proof gate does not apply; nevertheless, the PR body provides exact-head packed-install, external runtime-inspection, doctor, and Gateway lifecycle evidence.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This is a MEMBER-authored PR, so the external-contributor proof gate does not apply; nevertheless, the PR body provides exact-head packed-install, external runtime-inspection, doctor, and Gateway lifecycle evidence.
Evidence reviewed 7 items Current-main behavior: Current main still marks @openclaw/imessage private and does not declare external install or release metadata, so the requested externalization is not already implemented.
Upgrade owner boundary: The existing relocation bridge derives a replacement install from a persisted bundled plugin record and the official catalog, rather than hardcoding a channel-specific migration. The PR supplies iMessage with the catalog metadata that bridge requires.
PR release and catalog metadata: The proposed package explicitly declares npm and ClawHub publication, host compatibility, and non-bundled distribution; the official catalog maps the stable imessage channel id to the same install specs.
Findings None None.
Security None None.

How this fits together

The Gateway discovers configured channel plugins from the bundled distribution, persisted installed-plugin index, and official external catalog. For iMessage, this PR changes the distribution source while retaining the same plugin and channel identifier so configured users can install the external package and continue through the normal channel lifecycle.

flowchart LR
  A[Existing iMessage configuration] --> B[Gateway startup]
  B --> C[Persisted plugin index]
  C --> D[Relocation bridge]
  E[Official channel catalog] --> D
  D --> F[External iMessage package]
  F --> G[Gateway channel runtime]
  G --> H[Messages Mac via imsg]
Loading

Decision needed

Question Recommendation
Should supported iMessage remain a core-bundled channel, or should OpenClaw adopt this official external-package ownership model with coordinated release publication? Adopt official external ownership: Merge the PR and retain the catalog, recovery, and all-publishable release safeguards so installed iMessage users migrate through the supported plugin path.

Why: The code follows the established external-plugin and release mechanisms, but choosing whether a widely supported macOS channel leaves the default core distribution is a maintainer product and support-boundary decision.

Before merge

  • Resolve merge risk (P1) - An existing iMessage operator upgrading to the first core release without dist/extensions/imessage depends on the matching @openclaw/imessage npm package being published and installable; the release workflow provides the ordering guard, but maintainers must preserve that coordinated-release contract.
  • Complete next step (P2) - No narrow repair is indicated; the protected maintainer review should approve or reject the channel ownership and support boundary before merge.
Agent review details

Security

None.

PR surface

Tests +83, Docs +45, Config +25, Other +46. Total +199 across 23 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 4 83 0 +83
Docs 14 81 36 +45
Config 2 28 3 +25
Generated 0 0 0 0
Other 3 47 1 +46
Total 23 239 40 +199

Review metrics

Metric Value Why it matters
Distribution boundary 1 supported channel moved from bundled to official external This changes the upgrade path for every installed iMessage operator even though the channel id and configuration remain stable.

Merge-risk options

Maintainer options:

  1. Keep coordinated publication mandatory (recommended)
    Merge only with the current release guard intact: publish every eligible official plugin first and require the iMessage artifact to be installable before publishing the core npm package.
  2. Retain bundled distribution
    Pause or close the externalization if maintainers do not want an iMessage upgrade to depend on an independently published official package.

Technical review

Best possible solution:

Approve the external-plugin ownership direction only if iMessage remains in the official catalog with persisted-location recovery and the coordinated all-publishable release workflow is used before a core npm release omits the bundled artifact.

Do we have a high-confidence way to reproduce the issue?

Not applicable as a bug report. The relevant verification is the declared packed-install, persisted-index recovery, doctor, and Gateway startup path, for which the PR supplies exact-head Testbox evidence and focused regression coverage.

Is this the best way to solve the issue?

Yes, conditionally. The branch uses the existing generic persisted-plugin relocation mechanism and official external catalog instead of introducing iMessage-specific core fallback logic; the remaining question is whether maintainers want this channel ownership model.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against b8b4a11b3855.

Labels

Label justifications:

  • P2: The PR is a bounded but user-facing channel distribution change that needs normal maintainer prioritization.
  • merge-risk: 🚨 compatibility: The first core release that excludes the bundled iMessage artifact requires the matching external package and recovery route for existing operators.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This is a MEMBER-authored PR, so the external-contributor proof gate does not apply; nevertheless, the PR body provides exact-head packed-install, external runtime-inspection, doctor, and Gateway lifecycle evidence.

Evidence

What I checked:

  • Current-main behavior: Current main still marks @openclaw/imessage private and does not declare external install or release metadata, so the requested externalization is not already implemented. (extensions/imessage/package.json:4, b8b4a11b3855)
  • Upgrade owner boundary: The existing relocation bridge derives a replacement install from a persisted bundled plugin record and the official catalog, rather than hardcoding a channel-specific migration. The PR supplies iMessage with the catalog metadata that bridge requires. (src/cli/plugins-location-bridges.ts:20, b8b4a11b3855)
  • PR release and catalog metadata: The proposed package explicitly declares npm and ClawHub publication, host compatibility, and non-bundled distribution; the official catalog maps the stable imessage channel id to the same install specs. (extensions/imessage/package.json:76, 97c084528de3)
  • Release sequencing contract: The release workflow rejects an OpenClaw npm publication unless every publishable official plugin is included, dispatches plugin npm publication first, and documents that OpenClaw npm publication starts only after plugin npm succeeds. (.github/workflows/openclaw-release-publish.yml:210, b8b4a11b3855)
  • Publishable-package contract: The npm release planner selects packages whose openclaw.release.publishToNpm is true and rejects private packages or missing repository, README, install, and external-plugin contract metadata. (scripts/lib/plugin-npm-release.ts:413, b8b4a11b3855)
  • Feature provenance: Blame attributes the current iMessage manifest and persisted-location bridge to the July 31, 2026 plugin-discovery refactor, identifying the current owner boundary rather than the PR author alone. (src/cli/plugins-location-bridges.ts:24, 3972c4151390)

Likely related people:

  • Peter Steinberger: Current blame attributes the iMessage manifest and generic persisted bundled-plugin relocation bridge to the plugin-discovery refactor that established this upgrade boundary. (role: recent area contributor; confidence: high; commits: 3972c4151390; files: extensions/imessage/package.json, src/cli/plugins-location-bridges.ts)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Record maintainer approval of the external iMessage ownership boundary before merge.
  • Use the normal all-publishable release path and verify the published @openclaw/imessage artifact before releasing a core package that omits the bundled channel.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
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.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (2 earlier review cycles)
  • reviewed 2026-07-31T23:31:16.483Z sha 97c0845 :: needs maintainer review before merge. :: none
  • reviewed 2026-07-31T23:42:36.927Z sha 97c0845 :: needs maintainer review before merge. :: none

@vincentkoc
vincentkoc merged commit 89aadef into main Aug 1, 2026
142 of 148 checks passed
@vincentkoc
vincentkoc deleted the feat/externalize-imessage branch August 1, 2026 00:01
@vincentkoc

Copy link
Copy Markdown
Member Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

channel: imessage Channel integration: imessage cli CLI command changes dependencies-changed PR changes dependency-related files docs Improvements or additions to documentation gateway Gateway runtime maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. scripts Repository scripts size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant