π OpenHands: AI-Driven Development
chore: consume SDK 1.49.4 and Automation 1.14.0 (#17628)
Hiep Lefcf12f9ce729
diff --git a/.github/workflows/mock-llm-e2e.yml b/.github/workflows/mock-llm-e2e.ymlindex f79d50979b..41e117e149 100644--- a/.github/workflows/mock-llm-e2e.yml+++ b/.github/workflows/mock-llm-e2e.yml@@ -34,7 +34,6 @@ jobs:run: |echo "agent_server_version=$(node -p "require('./config/defaults.json').versions.agentServer")" >> "$GITHUB_OUTPUT"echo "automation_version=$(node -p "require('./config/defaults.json').versions.automation")" >> "$GITHUB_OUTPUT"- echo "acp_constraint=$(node -p "require('./config/defaults.json').constraints.agentClientProtocol")" >> "$GITHUB_OUTPUT"- name: Set up Node.jsuses: actions/setup-node@v7@@ -74,14 +73,9 @@ jobs:- name: Install openhands-sdk (for mock LLM server)env:AGENT_SERVER_VERSION: ${{ steps.defaults.outputs.agent_server_version }}- # Pin agent-client-protocol to the range openhands-sdk 1.35.0 is- # compatible with. acp 0.11.0 reordered the ACP prompt() args and- # breaks the SDK's ACP client; the mock ACP server runs from this- # venv, so keep it on the same acp version as the agent-server.- ACP_CONSTRAINT: ${{ steps.defaults.outputs.acp_constraint }}run: |uv venv .mock-llm-venv- uv pip install -p .mock-llm-venv "openhands-sdk==$AGENT_SERVER_VERSION" "$ACP_CONSTRAINT"+ uv pip install -p .mock-llm-venv "openhands-sdk==$AGENT_SERVER_VERSION"- name: Pre-warm automation backend (uvx cache)env:diff --git a/AGENTS.md b/AGENTS.mdindex 21fd828261..f4ea1ac5ea 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -597,10 +597,10 @@ When adding code that needs a new string, decide up front which rule it falls un- `scripts/dev-safe.mjs` uses `uvx` for temporary agent-server installation β no permanent `uv tool install` needed. Environment variables (highest precedence first):- `OH_AGENT_SERVER_LOCAL_PATH` β absolute path to a local `software-agent-sdk` checkout. Runs the local checkout via `uvx` with `--with-editable` for `openhands-sdk`/`openhands-tools`/`openhands-workspace` and `--reinstall` for `openhands-agent-server`, so SDK edits are picked up on restart. Highest precedence.- `OH_AGENT_SERVER_GIT_REF` β git commit SHA or branch name (takes precedence over version)- - `OH_AGENT_SERVER_VERSION` β specific PyPI version (e.g., "1.49.3")+ - `OH_AGENT_SERVER_VERSION` β specific PyPI version (e.g., "1.49.4")- `OH_SECRET_KEY` β secret key for settings encryption; auto-generated and persisted to `~/.openhands/agent-canvas/secret-key.txt` on first run (same file Docker uses), ensuring dev mode and Docker share the same key when both mount the same `~/.openhands` directory. Override with the env var to pin a specific key.- `SESSION_API_KEY` / `OH_SESSION_API_KEYS_0` / `VITE_SESSION_API_KEY` β session API key for agent-server authentication; auto-generated using `crypto.randomBytes(32)` if not set, passed to both agent-server (`OH_SESSION_API_KEYS_0`) and frontend (`VITE_SESSION_API_KEY`)- - Default: released PyPI version `1.49.3` for agent-server SDK libraries+ - Default: released PyPI version `1.49.4` for agent-server SDK libraries- Security: launchers generate and persist a 64-character session API key at `~/.openhands/agent-canvas/session-api-key.txt` unless overridden. The agent-server and automation backend share that session key. `OH_SECRET_KEY` protects settings encryption and is persisted separately at `~/.openhands/agent-canvas/secret-key.txt`.- `scripts/dev-safe.mjs` should fail fast if `uvx` cannot be spawned (for example missing PATH entries).diff --git a/__tests__/scripts/dev-safe.test.ts b/__tests__/scripts/dev-safe.test.tsindex fbd04614a9..ceeb649676 100644--- a/__tests__/scripts/dev-safe.test.ts+++ b/__tests__/scripts/dev-safe.test.ts@@ -492,22 +492,20 @@ describe("buildAgentServerCommand", () => {// Defaults to the released PyPI version with all SDK packages pinned to same versionexpect(cmd.args).toEqual(["--from",- "openhands-agent-server==1.49.3",+ "openhands-agent-server==1.49.4","--with",- "openhands-sdk==1.49.3",+ "openhands-sdk==1.49.4","--with",- "openhands-tools==1.49.3",+ "openhands-tools==1.49.4","--with",- "openhands-workspace==1.49.3",- "--with",- "agent-client-protocol<0.11",+ "openhands-workspace==1.49.4","--with","posthog>=6,<7","agent-server","--import-modules","canvas_ui_tool",]);- expect(cmd.source).toBe("PyPI (1.49.3, default)");+ expect(cmd.source).toBe("PyPI (1.49.4, default)");});it("uses specific PyPI version when OH_AGENT_SERVER_VERSION is set with all packages pinned", () => {@@ -526,8 +524,6 @@ describe("buildAgentServerCommand", () => {"--with","openhands-workspace==1.18.0","--with",- "agent-client-protocol<0.11",- "--with","posthog>=6,<7","agent-server","--import-modules",diff --git a/config/defaults.json b/config/defaults.jsonindex 3527ab6b06..496cb7e126 100644--- a/config/defaults.json+++ b/config/defaults.json@@ -1,17 +1,13 @@{"_comment": "Single source of truth for version pins, ports, paths, and defaults shared across the npm and Docker install paths. Read by scripts/dev-safe.mjs, scripts/dev-with-automation.mjs, docker/entrypoint.sh (via generated defaults.env), and .github/workflows/docker.yml.","versions": {- "agentServer": "1.49.3",+ "agentServer": "1.49.4","agentCanvas": "1.21.0",- "automation": "1.13.3"+ "automation": "1.14.0"},"compatibility": {"minimumAgentServer": "1.28.0"},- "constraints": {- "_comment": "Temporary upper bound on the agent-client-protocol (acp) transitive dependency. openhands-sdk 1.35.0 requires agent-client-protocol>=0.10.1 with no upper bound, but acp 0.11.0 reordered the ACP prompt() arguments and breaks the SDK's ACP client (a PromptRequest validation error surfaces as 'ACP error: 2 validation errors for PromptRequest'). Pin acp <0.11 until a fixed openhands-sdk ships. Consumed by scripts/dev-safe.mjs (agent-server uvx install) and .github/workflows/mock-llm-e2e.yml (mock ACP server venv).",- "agentClientProtocol": "agent-client-protocol<0.11"- },"images": {"agentServer": "ghcr.io/openhands/agent-server","agentCanvas": "ghcr.io/openhands/agent-canvas"diff --git a/package-lock.json b/package-lock.jsonindex e954066118..6473e7cbe4 100644--- a/package-lock.json+++ b/package-lock.json@@ -14,7 +14,7 @@"@microlink/react-json-view": "1.31.25","@monaco-editor/react": "4.7.0","@openhands/extensions": "0.22.1",- "@openhands/typescript-client": "1.49.3",+ "@openhands/typescript-client": "1.49.4","@react-router/node": "7.18.2","@react-router/serve": "7.18.2","@tailwindcss/vite": "4.3.3",@@ -4179,9 +4179,9 @@}},"node_modules/@openhands/typescript-client": {- "version": "1.49.3",- "resolved": "https://registry.npmjs.org/@openhands/typescript-client/-/typescript-client-1.49.3.tgz",- "integrity": "sha512-vR3izQ5MveCT5Ls6xhivzkXc/Qw3qOSB7COTzPaG39VZUPKX/KqXRx5JwJSZxeUtyO+WgwSSBJ3VJ0abX2DBLQ==",+ "version": "1.49.4",+ "resolved": "https://registry.npmjs.org/@openhands/typescript-client/-/typescript-client-1.49.4.tgz",+ "integrity": "sha512-dNwN4e9tgBR/xolZ6CQUrqKDg6P00od9MyKIcpPlwa7807h+KPDggtIbeHjz1kO1R2xvQWp7jVivsQrLeLAbGQ==","license": "MIT","dependencies": {"@openrouter/sdk": "^1.2.11",diff --git a/package.json b/package.jsonindex 35f89d7021..9c9568b169 100644--- a/package.json+++ b/package.json@@ -24,7 +24,7 @@"@microlink/react-json-view": "1.31.25","@monaco-editor/react": "4.7.0","@openhands/extensions": "0.22.1",- "@openhands/typescript-client": "1.49.3",+ "@openhands/typescript-client": "1.49.4","@react-router/node": "7.18.2","@react-router/serve": "7.18.2","@tailwindcss/vite": "4.3.3",diff --git a/scripts/check-sdk-version-sync.mjs b/scripts/check-sdk-version-sync.mjsindex 90acf5b0db..07c40f0d05 100644--- a/scripts/check-sdk-version-sync.mjs+++ b/scripts/check-sdk-version-sync.mjs@@ -26,7 +26,7 @@** Usage:* node scripts/check-sdk-version-sync.mjs- * EXPECTED_SDK_VERSION=1.49.3 node scripts/check-sdk-version-sync.mjs+ * EXPECTED_SDK_VERSION=1.49.4 node scripts/check-sdk-version-sync.mjs* node scripts/check-sdk-version-sync.mjs --check-pypi** Environment variables:@@ -85,7 +85,7 @@ Triggering from other repos:-H "Authorization: token \$GITHUB_TOKEN" \\-H "Accept: application/vnd.github.v3+json" \\https://api.github.com/repos/OpenHands/OpenHands/dispatches \\- -d '{"event_type": "sdk-version-check", "client_payload": {"version": "1.49.3"}}'+ -d '{"event_type": "sdk-version-check", "client_payload": {"version": "1.49.4"}}'`);process.exit(0);}@@ -300,9 +300,9 @@ async function fetchPyPIDependencies(packageName, version) {* Parse PyPI requires_dist array and extract SDK package versions** PyPI returns dependencies in PEP 508 format like:- * "openhands-sdk>=1.49.3,<2.0.0"- * "openhands-tools==1.49.3"- * "openhands-workspace (>=1.49.3)"+ * "openhands-sdk>=1.49.4,<2.0.0"+ * "openhands-tools==1.49.4"+ * "openhands-workspace (>=1.49.4)"*/function parseSdkVersionsFromRequiresDist(requiresDist) {const versions = {};@@ -316,7 +316,7 @@ function parseSdkVersionsFromRequiresDist(requiresDist) {}// Extract the version number - look for patterns like:- // ">=1.49.3", "==1.49.3", "(>=1.49.3)", "~=1.49.3"+ // ">=1.49.4", "==1.49.4", "(>=1.49.4)", "~=1.49.4"// After the package name and before any comma or closing parenconst versionPattern = /[><=~!]+\s*([0-9]+(?:\.[0-9]+)*)/;const match = dep.match(versionPattern);diff --git a/scripts/dev-safe.mjs b/scripts/dev-safe.mjsindex 7e6ded8e0f..4008c62bf4 100644--- a/scripts/dev-safe.mjs+++ b/scripts/dev-safe.mjs@@ -53,11 +53,6 @@ const LOCAL_AGENT_SERVER_SUBDIRS = ["openhands-workspace",];const DEFAULT_AGENT_SERVER_VERSION = SHARED_DEFAULTS.versions.agentServer;-// Temporary transitive-dep pin: openhands-sdk 1.40.1 leaves agent-client-protocol-// unbounded (>=0.10.1), but acp 0.11.0 reordered the ACP prompt() args and breaks-// the SDK's ACP client. Hold acp <0.11 until a fixed SDK ships. See config/defaults.json.-const AGENT_CLIENT_PROTOCOL_CONSTRAINT =- SHARED_DEFAULTS.constraints?.agentClientProtocol;const DEFAULT_AGENT_SERVER_TELEMETRY_POSTHOG_API_KEY =SHARED_DEFAULTS.telemetry.posthogApiKey;const DEFAULT_AGENT_SERVER_TELEMETRY_POSTHOG_HOST =@@ -421,7 +416,7 @@ export const AGENT_SERVER_IMPORT_MODULES = "canvas_ui_tool";* edits are picked up without a manual reinstall. The agent-server itself* is rebuilt from local source on each invocation (--reinstall).* - OH_AGENT_SERVER_GIT_REF: Git commit SHA or branch name- * - OH_AGENT_SERVER_VERSION: Specific PyPI version (e.g., "1.49.3")+ * - OH_AGENT_SERVER_VERSION: Specific PyPI version (e.g., "1.49.4")** If none are set, defaults to the released version specified by* DEFAULT_AGENT_SERVER_VERSION. Set OH_AGENT_SERVER_GIT_REF to use a@@ -499,9 +494,6 @@ export function buildAgentServerCommand(env = process.env) {"--with",`openhands-workspace==${version}`,);- if (AGENT_CLIENT_PROTOCOL_CONSTRAINT) {- uvxArgs.push("--with", AGENT_CLIENT_PROTOCOL_CONSTRAINT);- }uvxArgs.push("--with", AGENT_SERVER_POSTHOG_CONSTRAINT);uvxArgs.push("agent-server");source = `PyPI (${version})`;@@ -518,9 +510,6 @@ export function buildAgentServerCommand(env = process.env) {"--with",`openhands-workspace==${DEFAULT_AGENT_SERVER_VERSION}`,);- if (AGENT_CLIENT_PROTOCOL_CONSTRAINT) {- uvxArgs.push("--with", AGENT_CLIENT_PROTOCOL_CONSTRAINT);- }uvxArgs.push("--with", AGENT_SERVER_POSTHOG_CONSTRAINT);uvxArgs.push("agent-server");source = `PyPI (${DEFAULT_AGENT_SERVER_VERSION}, default)`;