Skip to content

πŸ™Œ OpenHands: AI-Driven Development

chore: Bump agent server and automation defaults (#16970)

Rohit Malhotrad573456dc693
diff --git a/.github/pr-assets/pr-16970-terminal-verification.svg b/.github/pr-assets/pr-16970-terminal-verification.svg
new file mode 100644
index 0000000000..84fff4498b
--- /dev/null
+++ b/.github/pr-assets/pr-16970-terminal-verification.svg
@@ -0,0 +1,12 @@
+<svg xmlns="http://www.w3.org/2000/svg" width="1180" height="360" role="img" aria-label="Terminal verification passed">
+ <rect width="100%" height="100%" rx="18" fill="#0b1020"/>
+ <circle cx="34" cy="32" r="8" fill="#ff5f56"/>
+ <circle cx="60" cy="32" r="8" fill="#ffbd2e"/>
+ <circle cx="86" cy="32" r="8" fill="#27c93f"/>
+ <text x="28" y="78" fill="#d7e2ff" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">$ node scripts/check-sdk-version-sync.mjs</text>
+ <text x="28" y="116" fill="#8ef0a1" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">All SDK versions are in sync!</text>
+ <text x="28" y="170" fill="#d7e2ff" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">$ npm test -- --run __tests__/scripts/docs-version-sync.test.ts __tests__/scripts/dev-safe.test.ts __tests__/scripts/check-sdk-version-sync.test.ts</text>
+ <text x="28" y="208" fill="#8ef0a1" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">Test Files 3 passed (3) Β· Tests 81 passed (81)</text>
+ <text x="28" y="262" fill="#d7e2ff" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">$ npm test</text>
+ <text x="28" y="300" fill="#8ef0a1" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" font-size="22">Test Files 619 passed (619) Β· Tests 5220 passed | 4 skipped | 7 todo</text>
+</svg>
diff --git a/.github/workflows/mock-llm-e2e.yml b/.github/workflows/mock-llm-e2e.yml
index ac191fd740..a053763614 100644
--- a/.github/workflows/mock-llm-e2e.yml
+++ b/.github/workflows/mock-llm-e2e.yml
@@ -193,6 +193,7 @@ jobs:
id: run_tests
env:
MOCK_LLM_PYTHON: .mock-llm-venv/bin/python3
+ MOCK_LLM_GLOBAL_TIMEOUT_MS: 1200000
AFFECTED_TEST_PATHS: ${{ steps.affected_tests.outputs.test_paths }}
SELECTIVE_TESTS: ${{ steps.affected_tests.outputs.selective }}
run: |
@@ -216,13 +217,13 @@ jobs:
$PW_CMD &
PW_PID=$!
- # Wait for tests to complete. Playwright's globalTimeout is 600s
- # (10 min) in CI; we add 60s buffer for webServer startup/teardown.
+ # Wait for tests to complete. Playwright's globalTimeout is 20 min
+ # in CI; we add 60s buffer for webServer startup/teardown.
# The custom DoneMarkerReporter writes .tests-done only after ALL
# tests finish (pass or fail), before webServer teardown begins.
# .results.json is flushed after every single test, so even if we
# hit the deadline mid-suite the report script still has data.
- deadline=$((SECONDS + 660))
+ deadline=$((SECONDS + (MOCK_LLM_GLOBAL_TIMEOUT_MS / 1000) + 60))
while [ "$SECONDS" -lt "$deadline" ]; do
if ! kill -0 "$PW_PID" 2>/dev/null; then
break
diff --git a/AGENTS.md b/AGENTS.md
index adc22cbafb..c473b966f6 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -268,7 +268,7 @@ you are running inside of β€” NOT the automation backend.
- `regressions/` β€” CSS isolation, event pagination, workspace persistence (`mock-llm-ui-regressions.spec.ts`). Always included in selective runs.
- **Selective test execution**: `tests/e2e/mock-llm/test-mapping.json` maps source paths to test subdirectories. The `tests/e2e/mock-llm/scripts/resolve-affected-tests.mjs` script reads the PR's changed files and outputs which test directories to run. Four resolution modes: (1) changed files match specific `mappings` β†’ run only those subdirs + `regressions`; (2) changed mock-LLM spec files β†’ run the containing feature subdirectory + `regressions`, so test-only PRs that add new specs still execute the new tests; (3) changed files match `runAllSources` patterns (cross-cutting files like `src/api/agent-server-adapter.ts`, `package.json`, shared test helpers, or `test-mapping.json`) or are unmapped `src/` files β†’ run full suite (`__ALL__`); (4) changed files are outside the E2E-relevant tree (docs, specs) β†’ nothing; the workflow still starts so required checks do not remain pending, but the heavy test job is skipped by its internal change detector. The CI workflow's "Resolve affected test directories" step runs the script and passes the result to Playwright; `workflow_dispatch` always runs the full suite.
- Tests run serially (`workers: 1`, `mode: "serial"` per describe block). Each spec is self-contained (configures its own LLM profile, resets mock LLM in `afterEach`). The `afterEach` hook resets the mock LLM to its default trajectory so subsequent specs start fresh even when a preceding test fails.
-- CI workflow: `.github/workflows/mock-llm-e2e.yml` runs on PR commits (opened, synchronize, reopened) and on manual dispatch. It intentionally does **not** use `pull_request.paths` filters, because path-skipped workflows can leave required checks pending. Instead a lightweight `detect-pr-changes` job marks the heavy `mock-llm-e2e` job skipped-success for PRs that only touch docs, specs, or other non-stack files. Relevant paths are `src/**`, `public/**`, `scripts/**`, `bin/**`, `config/**`, `tests/e2e/mock-llm/**`, `tests/e2e/support/**`, `package.json`, `package-lock.json`, build/TS configs, styling configs, and the workflow file itself. `workflow_dispatch` is unaffected by path filters and always runs. The workflow builds the frontend, starts the mock LLM server, runs the tests, and posts a PR comment with results. `render-mock-llm-report.mjs` keeps only the heading/summary/commit links visible and wraps the full test table in a `<details><summary>Details</summary>` block. `upsert-pr-comment.mjs` deletes any older comment for the same mock-LLM job (matched by hidden marker or the legacy bot-authored heading) before posting the latest report, so same-job comments do not accumulate. The PR comment marks tests from newly added spec files with a πŸ†• badge; the "Detect newly added spec files" step queries the GitHub API for files with `status == "added"` matching `tests/e2e/mock-llm/**/*.spec.ts`, and passes them as `--new-files` to `render-mock-llm-report.mjs`. The summary line shows the count of new tests (e.g. `πŸ†• 2 new`). The same detection and comment replacement flow are wired into the Docker E2E workflow (`mock-llm-docker-e2e.yml`).
+- CI workflow: `.github/workflows/mock-llm-e2e.yml` runs on PR commits (opened, synchronize, reopened) and on manual dispatch. It intentionally does **not** use `pull_request.paths` filters, because path-skipped workflows can leave required checks pending. Instead a lightweight `detect-pr-changes` job marks the heavy `mock-llm-e2e` job skipped-success for PRs that only touch docs, specs, or other non-stack files. Relevant paths are `src/**`, `public/**`, `scripts/**`, `bin/**`, `config/**`, `tests/e2e/mock-llm/**`, `tests/e2e/support/**`, `package.json`, `package-lock.json`, build/TS configs, styling configs, and the workflow file itself. `workflow_dispatch` is unaffected by path filters and always runs. The workflow builds the frontend, starts the mock LLM server, runs the tests, and posts a PR comment with results. Npm-path Mock-LLM CI uses `MOCK_LLM_GLOBAL_TIMEOUT_MS` (default 20 min) and the workflow deadline adds a 60-second teardown buffer; keep `playwright.mock-llm.config.ts` and `.github/workflows/mock-llm-e2e.yml` in sync if that timeout changes. `render-mock-llm-report.mjs` keeps only the heading/summary/commit links visible and wraps the full test table in a `<details><summary>Details</summary>` block. `upsert-pr-comment.mjs` deletes any older comment for the same mock-LLM job (matched by hidden marker or the legacy bot-authored heading) before posting the latest report, so same-job comments do not accumulate. The PR comment marks tests from newly added spec files with a πŸ†• badge; the "Detect newly added spec files" step queries the GitHub API for files with `status == "added"` matching `tests/e2e/mock-llm/**/*.spec.ts`, and passes them as `--new-files` to `render-mock-llm-report.mjs`. The summary line shows the count of new tests (e.g. `πŸ†• 2 new`). The same detection and comment replacement flow are wired into the Docker E2E workflow (`mock-llm-docker-e2e.yml`).
- The custom `DoneMarkerReporter` writes `.mock-llm-markers/.tests-done` after all tests complete (before webServer teardown) so the CI wrapper can detect completion and kill the lingering teardown process.
### Docker Image Testing (Shared Specs)
@@ -581,10 +581,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.44.0")
+ - `OH_AGENT_SERVER_VERSION` β€” specific PyPI version (e.g., "1.44.1")
- `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.44.0` for agent-server SDK libraries
+ - Default: released PyPI version `1.44.1` 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.ts
index d2f56872a3..a39a5eec6a 100644
--- a/__tests__/scripts/dev-safe.test.ts
+++ b/__tests__/scripts/dev-safe.test.ts
@@ -468,13 +468,13 @@ describe("buildAgentServerCommand", () => {
// Defaults to the released PyPI version with all SDK packages pinned to same version
expect(cmd.args).toEqual([
"--from",
- "openhands-agent-server==1.44.0",
+ "openhands-agent-server==1.44.1",
"--with",
- "openhands-sdk==1.44.0",
+ "openhands-sdk==1.44.1",
"--with",
- "openhands-tools==1.44.0",
+ "openhands-tools==1.44.1",
"--with",
- "openhands-workspace==1.44.0",
+ "openhands-workspace==1.44.1",
"--with",
"agent-client-protocol<0.11",
"--with",
@@ -483,7 +483,7 @@ describe("buildAgentServerCommand", () => {
"--import-modules",
"canvas_ui_tool",
]);
- expect(cmd.source).toBe("PyPI (1.44.0, default)");
+ expect(cmd.source).toBe("PyPI (1.44.1, default)");
});
it("uses specific PyPI version when OH_AGENT_SERVER_VERSION is set with all packages pinned", () => {
diff --git a/config/defaults.json b/config/defaults.json
index 9653171b17..1a406a2553 100644
--- a/config/defaults.json
+++ b/config/defaults.json
@@ -1,9 +1,9 @@
{
"_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.44.0",
+ "agentServer": "1.44.1",
"agentCanvas": "1.16.0",
- "automation": "1.9.0"
+ "automation": "1.9.1"
},
"compatibility": {
"minimumAgentServer": "1.28.0"
diff --git a/playwright.mock-llm.config.ts b/playwright.mock-llm.config.ts
index 333a3036bb..cc1e499ef8 100644
--- a/playwright.mock-llm.config.ts
+++ b/playwright.mock-llm.config.ts
@@ -75,6 +75,16 @@ function envAssignment(name: string, value: string) {
return `${name}=${shellQuote(value)}`;
}
+const DEFAULT_CI_GLOBAL_TIMEOUT_MS = 1_200_000;
+const configuredCiGlobalTimeoutMs = Number.parseInt(
+ process.env.MOCK_LLM_GLOBAL_TIMEOUT_MS ??
+ String(DEFAULT_CI_GLOBAL_TIMEOUT_MS),
+ 10,
+);
+const ciGlobalTimeoutMs = Number.isFinite(configuredCiGlobalTimeoutMs)
+ ? configuredCiGlobalTimeoutMs
+ : DEFAULT_CI_GLOBAL_TIMEOUT_MS;
+
export default defineConfig({
testDir: "./tests/e2e/mock-llm",
testMatch: /.*\.spec\.ts/,
@@ -83,7 +93,7 @@ export default defineConfig({
retries: 0,
workers: 1,
timeout: 60_000,
- globalTimeout: process.env.CI ? 600_000 : 0, // 10 min hard cap in CI
+ globalTimeout: process.env.CI ? ciGlobalTimeoutMs : 0, // 20 min hard cap in CI
reporter: [
["line"],
["json", { outputFile: "test-results-mock-llm/results.json" }],
diff --git a/scripts/check-sdk-version-sync.mjs b/scripts/check-sdk-version-sync.mjs
index 80c67c9c1f..e5acd72bee 100644
--- a/scripts/check-sdk-version-sync.mjs
+++ b/scripts/check-sdk-version-sync.mjs
@@ -19,7 +19,7 @@
*
* Usage:
* node scripts/check-sdk-version-sync.mjs
- * EXPECTED_SDK_VERSION=1.44.0 node scripts/check-sdk-version-sync.mjs
+ * EXPECTED_SDK_VERSION=1.44.1 node scripts/check-sdk-version-sync.mjs
* node scripts/check-sdk-version-sync.mjs --check-pypi
*
* Environment variables:
@@ -78,7 +78,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.44.0"}}'
+ -d '{"event_type": "sdk-version-check", "client_payload": {"version": "1.44.1"}}'
`);
process.exit(0);
}
@@ -260,9 +260,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.44.0,<2.0.0"
- * "openhands-tools==1.44.0"
- * "openhands-workspace (>=1.44.0)"
+ * "openhands-sdk>=1.44.1,<2.0.0"
+ * "openhands-tools==1.44.1"
+ * "openhands-workspace (>=1.44.1)"
*/
function parseSdkVersionsFromRequiresDist(requiresDist) {
const versions = {};
@@ -276,7 +276,7 @@ function parseSdkVersionsFromRequiresDist(requiresDist) {
}
// Extract the version number - look for patterns like:
- // ">=1.44.0", "==1.44.0", "(>=1.44.0)", "~=1.44.0"
+ // ">=1.44.1", "==1.44.1", "(>=1.44.1)", "~=1.44.1"
// After the package name and before any comma or closing paren
const versionPattern = /[><=~!]+\s*([0-9]+(?:\.[0-9]+)*)/;
const match = dep.match(versionPattern);
diff --git a/scripts/dev-safe.mjs b/scripts/dev-safe.mjs
index e411ca3184..ad8edf967a 100644
--- a/scripts/dev-safe.mjs
+++ b/scripts/dev-safe.mjs
@@ -421,7 +421,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.44.0")
+ * - OH_AGENT_SERVER_VERSION: Specific PyPI version (e.g., "1.44.1")
*
* If none are set, defaults to the released version specified by
* DEFAULT_AGENT_SERVER_VERSION. Set OH_AGENT_SERVER_GIT_REF to use a