Skip to content

chore(deps): bump relaycast SDKs to latest#1203

Merged
willwashburn merged 2 commits into
mainfrom
chore/bump-relaycast-latest
Jun 27, 2026
Merged

chore(deps): bump relaycast SDKs to latest#1203
willwashburn merged 2 commits into
mainfrom
chore/bump-relaycast-latest

Conversation

@willwashburn

@willwashburn willwashburn commented Jun 27, 2026

Copy link
Copy Markdown
Member

Upgrades every relaycast SDK dependency to its latest published version.

Version bumps

Ecosystem Package From To
npm @relaycast/sdk (packages/sdk, packages/cli) ^4.1.6 ^5.0.5 (v4→v5 major)
Rust relaycast crate (crates/broker) =5.0.1 =5.0.2
PyPI relaycast-sdk (packages/sdk-py, communicate + dev) >=0.2.0 >=0.3.0
Swift relaycast git dep (packages/sdk-swift) 4.2.0 5.0.5

Lockfiles: package-lock.json regenerated (npm install); Cargo.lock bumped relaycast 5.0.1→5.0.2; packages/sdk-swift/Package.resolved resolved to tag 5.0.5. packages/sdk-py/uv.lock intentionally not touched — main's lock is already stale against its own pyproject (re-resolving pulls ~32 unrelated transitive bumps), so that drift is left to a dedicated lock-refresh; relaycast-sdk 0.3.0 resolves cleanly against the bumped constraint.

v4→v5 code adaptation (TS)

The v5 @relaycast/sdk reworked agent release to flow through the action-invocation pipeline (consistent with the node-only delivery migration #1201):

  • Before (v4): relay.agents.release(...) returned a synchronous result { name, removed, deleted, reason }.
  • After (v5): relay.agents.release(...) returns an action invocation — same shape as agents.spawn ({ invocationId, actionName, handlerAgentId, handlerNodeId, dispatchedNodeId?, input, status, createdAt }).

packages/cli/src/cli/agent-relay-mcp.ts — the remove_agent MCP tool read the removed name/released/deleted/reason fields, breaking tsc. Updated to surface the invocation ({ invocation } with the permissive jsonResult output schema), mirroring the existing spawn tool.

All other relay imports (RelayCast, RelayError, RelayErrorCode, AgentClientOptions, RelayCastOptions, SDK_VERSION, WsClient, AgentClient) are unchanged in v5. The Rust 5.0.1→5.0.2 patch and the Swift 5.0.5 API needed no code changes.

Per-ecosystem verification (local)

  • Broker (Rust): cargo build -p agent-relay-broker ✅ · cargo test -p agent-relay-broker791 + 12 + 1 passed, 0 failed · cargo clippy -p agent-relay-broker ✅ clean.
  • TS sdk: build/typecheck ✅ · node-test-runner vitest ✅ 110/110.
  • TS cli + all packages: tsc build ✅ (fixed the v5 breakage above) · broker integration tests typecheck ✅ · vitest run969 passed, 5 skipped, 0 failed (79 files). (The repo-wide npm test glob also sweeps the Swift .build/checkouts/relaycast vendored checkout's own tests; excluding that path — which CI does, since the Swift checkout isn't populated on Linux CI — relay's own suite is fully green.)
  • sdk-py: relaycast-sdk 0.3.0 resolves; pytest279 passed (incl. all communicate/relaycast transport tests). 4 pre-existing failures (test_dry_run, test_relay_lifecycle_hooks) are a relay-source sessionId payload mismatch on main — reproduced identically with relaycast-sdk 0.2.0, so unrelated to this bump.
  • sdk-swift: swift build ✅ against tag 5.0.5 · swift test70 tests, 0 failures.

🤖 Generated with Claude Code

Upgrade every relaycast SDK dependency to its latest published version:

- npm @relaycast/sdk ^4.1.6 -> ^5.0.5 (v4->v5 major) in packages/sdk + packages/cli
- Rust relaycast crate =5.0.1 -> =5.0.2 in crates/broker
- PyPI relaycast-sdk >=0.2.0 -> >=0.3.0 (communicate + dev extras)
- Swift relaycast git dep 4.2.0 -> 5.0.5

v5 migration: agents.release now returns an action invocation (matching
agents.spawn) instead of the synchronous { name, removed, deleted, reason }
result. The remove_agent MCP tool now surfaces that invocation via jsonResult.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Relaycast SDK version pins were updated across the CLI, SDK, broker, Python, and Swift packages, and remove_agent now returns the raw agents.release invocation under jsonResult.

Changes

Relaycast SDK upgrade and MCP invocation response

Layer / File(s) Summary
remove_agent response contract
packages/cli/src/cli/agent-relay-mcp.ts, CHANGELOG.md
remove_agent switches to jsonResult and returns { invocation } from agents.release; the changelog notes the upgrade and the new invocation-based behavior.
JavaScript SDK dependency bumps
packages/cli/package.json, packages/sdk/package.json
The CLI and SDK package manifests update @relaycast/sdk to ^5.0.5.
Python, Rust, and Swift pins
packages/sdk-py/pyproject.toml, crates/broker/Cargo.toml, packages/sdk-swift/Package.swift, packages/sdk-swift/Package.resolved
The Python optional dependencies, broker crate, and Swift package files update Relaycast-related version constraints to v5-compatible releases.

Sequence Diagram(s)

sequenceDiagram
  participant MCPClient
  participant remove_agent
  participant RelaycastSDK
  MCPClient->>remove_agent: name, reason, deleteAgent
  remove_agent->>RelaycastSDK: agents.release({ name, reason, deleteAgent })
  RelaycastSDK-->>remove_agent: invocation
  remove_agent-->>MCPClient: { invocation }
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

  • AgentWorkforce/relay#1177 — Updates agent-relay-mcp docs to match the invocation-based result shape that remove_agent now returns.

Suggested reviewers

  • khaliqgant

Poem

I hopped through versions, v5 in sight,
with remove_agent bouncing bright.
The relay returns invocation flair,
and pins all snugly leap through air.
🐇✨ Hooray for tidy bytes!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: bumping relaycast SDK dependencies.
Description check ✅ Passed The description includes a clear summary and detailed verification, matching the template's intent.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/bump-relaycast-latest

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request upgrades the relaycast SDKs across multiple languages and packages to their latest versions, including a major version bump (v4 to v5) for @relaycast/sdk. This major upgrade changes agents.release to return an action invocation, and the remove_agent MCP tool in the CLI has been updated accordingly. The review feedback correctly points out that, per the repository style guide, this breaking change should be documented under a ### Breaking Changes section in the changelog rather than ### Changed.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread CHANGELOG.md
Comment on lines +12 to 13
- relaycast SDKs upgraded to latest: `@relaycast/sdk` 5.0.5 (v4→v5 major), `relaycast` crate 5.0.2, `relaycast-sdk` 0.3.0, Swift relaycast 5.0.5. The v5 `agents.release` now returns an action invocation (like `agents.spawn`); the `remove_agent` MCP tool surfaces that invocation.
- The hosted engine base URL default is owned solely by the relaycast SDK. `agent-relay`, `agent-relay-broker`, and the bundled SDKs no longer hardcode a base URL — they pass `RELAYCAST_BASE_URL`/`RELAY_BASE_URL` through for self-hosting and otherwise inherit the SDK default (`cast.agentrelay.com`). The broker reaches the fleet node-control endpoint via the SDK's `node_control_ws_url` helper and only injects `RELAY_BASE_URL` into spawned agents when an override is set.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

According to the repository style guide, we should use Breaking Changes and Migration Guidance sections when a SemVer-major change needs explicit callouts.

Since the upgrade of @relaycast/sdk from v4 to v5 is a major version bump that changes the return type of agents.release (returning an action invocation instead of a synchronous result), this breaking change should be documented under a ### Breaking Changes section rather than just ### Changed.

Suggested change
- relaycast SDKs upgraded to latest: `@relaycast/sdk` 5.0.5 (v4→v5 major), `relaycast` crate 5.0.2, `relaycast-sdk` 0.3.0, Swift relaycast 5.0.5. The v5 `agents.release` now returns an action invocation (like `agents.spawn`); the `remove_agent` MCP tool surfaces that invocation.
- The hosted engine base URL default is owned solely by the relaycast SDK. `agent-relay`, `agent-relay-broker`, and the bundled SDKs no longer hardcode a base URL — they pass `RELAYCAST_BASE_URL`/`RELAY_BASE_URL` through for self-hosting and otherwise inherit the SDK default (`cast.agentrelay.com`). The broker reaches the fleet node-control endpoint via the SDK's `node_control_ws_url` helper and only injects `RELAY_BASE_URL` into spawned agents when an override is set.
- relaycast SDKs upgraded to latest: @relaycast/sdk 5.0.5 (v4->v5 major), relaycast crate 5.0.2, relaycast-sdk 0.3.0, Swift relaycast 5.0.5.
- The hosted engine base URL default is owned solely by the relaycast SDK. agent-relay, agent-relay-broker, and the bundled SDKs no longer hardcode a base URL - they pass RELAYCAST_BASE_URL/RELAY_BASE_URL through for self-hosting and otherwise inherit the SDK default (cast.agentrelay.com). The broker reaches the fleet node-control endpoint via the SDK's node_control_ws_url helper and only injects RELAY_BASE_URL into spawned agents when an override is set.
### Breaking Changes
- SDKs / MCP: @relaycast/sdk v5 major upgrade. agents.release now returns an action invocation (matching agents.spawn shape) instead of a synchronous result. The remove_agent MCP tool has been updated to surface this invocation.
References
  1. Use Keep a Changelog sections (Added, Changed, Deprecated, Removed, Fixed, Security), plus Breaking Changes and Migration Guidance when a SemVer-major change needs explicit callouts. (link)

Resolves the relaycast git dependency lockfile to tag 5.0.5, matching
the Package.swift constraint bump. swift build + swift test (70 tests)
pass against 5.0.5.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@willwashburn willwashburn marked this pull request as ready for review June 27, 2026 00:58
@willwashburn willwashburn requested a review from khaliqgant as a code owner June 27, 2026 00:58

@coderabbitai coderabbitai Bot 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.

🧹 Nitpick comments (1)
CHANGELOG.md (1)

12-12: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Split and shorten this changelog entry.

Line 12 packs multiple changes into one long bullet and includes implementation detail/version inventory, which makes [Unreleased] harder to scan.

Suggested rewrite
-- relaycast SDKs upgraded to latest: `@relaycast/sdk` 5.0.5 (v4→v5 major), `relaycast` crate 5.0.2, `relaycast-sdk` 0.3.0, Swift relaycast 5.0.5. The v5 `agents.release` now returns an action invocation (like `agents.spawn`); the `remove_agent` MCP tool surfaces that invocation.
+- Relaycast SDKs were upgraded to v5-compatible releases across the CLI, SDK, broker, Python, and Swift packages.
+- `remove_agent` now returns the release invocation payload.

As per coding guidelines, CHANGELOG.md entries should be concise and impact-first, with one short bullet per user-visible change, and should omit implementation details.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@CHANGELOG.md` at line 12, Split the long CHANGELOG entry into multiple short,
impact-first bullets under the Unreleased section instead of one inventory-style
sentence. Keep the focus on user-visible changes by separating the SDK upgrade
note from the agents.release/remove_agent behavior change, and remove
implementation details and version listings from the changelog. Use the existing
CHANGELOG.md entry as the target for the rewrite.

Source: Coding guidelines

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@CHANGELOG.md`:
- Line 12: Split the long CHANGELOG entry into multiple short, impact-first
bullets under the Unreleased section instead of one inventory-style sentence.
Keep the focus on user-visible changes by separating the SDK upgrade note from
the agents.release/remove_agent behavior change, and remove implementation
details and version listings from the changelog. Use the existing CHANGELOG.md
entry as the target for the rewrite.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 83f29477-fd4d-4518-89e6-0ecfef4ab369

📥 Commits

Reviewing files that changed from the base of the PR and between f2dfd52 and 731be72.

⛔ Files ignored due to path filters (2)
  • Cargo.lock is excluded by !**/*.lock
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (8)
  • CHANGELOG.md
  • crates/broker/Cargo.toml
  • packages/cli/package.json
  • packages/cli/src/cli/agent-relay-mcp.ts
  • packages/sdk-py/pyproject.toml
  • packages/sdk-swift/Package.resolved
  • packages/sdk-swift/Package.swift
  • packages/sdk/package.json

@willwashburn willwashburn merged commit 2a5a43a into main Jun 27, 2026
48 checks passed
@willwashburn willwashburn deleted the chore/bump-relaycast-latest branch June 27, 2026 01:05
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.

1 participant