Repository navigation
feat(openhands): add the OpenHands harness adapter - #5543
Conversation
Add responses_api_agents/openhands_agent, a session-only adapter that runs the OpenHands Software Agent SDK 1.59.0 headless inside the task sandbox through SandboxSession. Seed installs a private runtime (a verified standalone CPython 3.13.14 uploaded from the Agent Server, then the hash-locked OpenHands packages from PyPI) and refuses seeds it cannot serve. Every model call, including condenser summaries, goes to the rollout-prefixed Model Server URL with an x-session-id header. OpenHands state stays in a session directory outside the task repository and home. Register openhands_agent as an agent-session type so its unbound config gets no legacy relay. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
The first real TB2.1 smoke on ws found three gaps: - OpenHands 1.59.0's subprocess terminal left bash 5.1+ bracketed-paste codes (ESC[?2004h) in tool output. Point INPUTRC at a session file that includes the task's readline file and turns bracketed paste off. - The condenser's summary call was referenced by the invocation, so the collector built a policy step from it (TE-9 steps.attempt_accounting). Reference it only from its compaction record. - Sandbox and tool-call records had no sandbox_id (TE-6 sandbox.identity). Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
…nhands-sessions-968c2f Signed-off-by: yaoyu-33 <[email protected]>
…failure Main replaced HarnessTerminationError with the NgFailureEvent that harness_termination_failure returns (#5072, #5536). Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
…ness docs openhands_agent answers /run with 422, so the legacy environment-server migration now skips it whatever its Resources binding, as it does for Stirrup. The agent-server docs list it in both harness tables. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 842fa3f |
Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 9d632e1 |
Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
…d uv.lock Main manages every component's dependencies with a pyproject.toml and a uv lock that share the root uv policy. Replace requirements.txt with a pyproject.toml copied from pi_agent's, declare openhands-sdk and openhands-tools 1.59.0 so the Agent Server environment pins the versions the sandbox runtime installs, and lock it with uv 0.13.7. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
…nhands-sessions-968c2f Signed-off-by: yaoyu-33 <[email protected]>
Replace the adapter's own installer (a standalone CPython uploaded by the Agent Server, then pip install from PyPI inside the sandbox) with Gym's SandboxPythonRuntime, as stirrup_agent does. The Agent Server host builds the runtime with uv at the versions its own environment pins, so the sandbox needs no network. func-timeout, which openhands-tools pins and which ships only an sdist, is given as a direct URL with its sha256 so the host builds it. The runner keeps its openhands-gym name through a link beside python/. Remove install_openhands_runtime.sh, sandbox_requirements.txt, the runtime fingerprint and the cross-agent cached_download import; add tests for runtime reuse, installation, the interpreter link, staging with a background process, and collection. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
Main now requires each server to commit a pyproject.toml and uv.lock (#4837). The adapter uses the same dependencies as the other sandboxed agents, so its project and lock match codex_agent's apart from the name. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 973f39c |
giuliolovisotto
left a comment
There was a problem hiding this comment.
Verified the previously reported fixes in the current source and regression assertions. My review findings are addressed. Harness conformance gaps remain non-blocking follow-up work. No new test-suite run was performed for this approval.
— @codex
Picks up ad91093 (#5909), which stops the agentic_if_realworld resume tests from failing when the checkout is dirty. CI's server suite hit that failure at c165acb. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 03b5704 |
main's #5946 split test_add_legacy_agent_environment_servers.py into several test_agent_environment_*.py files. Take main's version of that file and move this branch's two OpenHands migration tests into test_agent_environment_default_configs.py, beside the Claude Code test they followed before the split. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 1558ce3 |
Signed-off-by: yaoyu-33 <[email protected]> (cherry picked from commit 9ba42b1)
|
/ok to test f80584f |
main's #5082 added Copilot to the same two places as this branch's OpenHands lines. Keep both: - add_legacy_agent_environment_servers.py: Stirrup, Copilot and OpenHands all run only in agent sessions, so none gets a legacy relay. - integrate-existing-agents.mdx: both harness rows. The OpenHands cell for Harbor task folders now reads "Not validated", main's wording for a harness not yet run on one, so the column uses a single term. The agentic_if_realworld test fix pushed to this branch is also in main; after the merge those files match main. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 78d07be |
main's #5654 added a mini-SWE row to the adapter tool table in add-or-update-a-harness.mdx, right where this branch adds the OpenHands row. Keep both rows. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 28edfb9 |
Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 5cb82af |
Keep main's corrected OpenClaw token_id_capture note alongside the OpenHands harness row. Align the OpenHands lockfile with main's OpenAI 2.45.0 pin; the adapter runtime and tests remain unchanged. Linux workstation validation passed: 136 OpenHands tests, one registry contract, five migration cases, 29 documentation link tests, and full pre-commit. Fern check reported zero errors and one warning because its authenticated redirect check was unavailable. Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test a178dc7 |
giuliolovisotto
left a comment
There was a problem hiding this comment.
Re-approving after comparing this head with the previously approved 03b57040f2. The OpenHands implementation, tests and README are unchanged; its lockfile follows the main-branch OpenAI 2.45 pin. I also checked the small PR-rehearsal changelog adjustment and the upstream test update.
The previous failure-reporting fixes remain intact. Adapter tests at this head: 131 passed, 5 skipped using OpenAI 2.45.0; the skips require the native OpenHands SDK, which was not installed in this review environment. No native rollout or CI execution was performed. Existing harness-conformance gaps remain non-blocking follow-up work.
— @codex
main's #5537 added Droid in the same two places as this branch's OpenHands lines. Keep both: - add_legacy_agent_environment_servers.py: Stirrup, Copilot, Droid and OpenHands all run only in agent sessions, so none gets a legacy relay. - test_agent_environment_default_configs.py: main's file with the Droid tests, plus this branch's two OpenHands tests before them, unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
|
/ok to test 5a4a621 |
giuliolovisotto
left a comment
There was a problem hiding this comment.
Re-approving after checking the merge from the previously approved a178dc7. The OpenHands adapter, tests and lockfile are unchanged. The two conflict resolutions preserve both Droid and OpenHands session-only migration behavior and their tests. Previous failure-reporting fixes remain intact.
Validation at 5a4a621: OpenHands adapter tests 131 passed, 5 skipped; default-agent migration/composition tests 29 passed. The latter used package metadata generated from this source with OpenAI 2.45.0. The skips require the native OpenHands SDK. No native rollout or CI execution was performed. Existing conformance gaps remain follow-up work.
— @codex
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/43284699370 |
Merges with
mainon 2026-11-11 and 2026-11-12main, keepsmain's corrected OpenClawtoken_id_capturenote next to the OpenHands row, and aligns the OpenHands lockfile withmain'sopenai==2.45.0pin. Its commit message lists the validation.mainat33a498938.main's feat(droid): add the Factory Droid harness adapter #5537 added Droid in the same two places as this PR's OpenHands lines. The merge keeps both: Stirrup, Copilot, Droid and OpenHands all skip the legacy relay inadd_legacy_agent_environment_servers.py, andtest_agent_environment_default_configs.pykeepsmain's Droid tests plus this PR's two OpenHands tests, unchanged. Validation:ruff checkandruff format --checkon both files. In that test file, the tests that run the migration script on an OpenHands or Droid config passed. The tests that also parse the composed config could not run locally: the environment available had nemo-gym metadata pinningopenai==2.44.0, and the config loader refuses that mismatch withmain's 2.45.0. All 25 such failures were that error; CI runs them. Rollouts: none; the adapter is unchanged.Fifth merge with
main(2026-11-10)28edfb99a merges
mainat65dd99e96.main's #5654 added a mini-SWE row to the adapter tool table inadd-or-update-a-harness.mdx, in the same place as this PR's OpenHands row; the merge keeps both rows. Validation on a Linux workstation:responses_api_agents/openhands_agent/tests,tests/unit_tests/tooling,tests/unit_tests/agents,tests/unit_tests/configandtest_fern_docs_links.py: 1741 passed, 6 skipped, 1 failed, the sametest_update_env_list.pyfailure described in the next section. Rollouts: none; the adapter is unchanged.Fourth merge with
main(2026-11-10)78d07be31 merges
mainatbdf8c9afa. The PR had left the merge queue becausemain's #5082 added Copilot in the same two places as this PR's OpenHands lines. The merge keeps both:scripts/add_legacy_agent_environment_servers.py: Stirrup, Copilot and OpenHands all run only in agent sessions, so none of them gets a legacy relay.integrate-existing-agents.mdx: both harness rows. OpenHands' "Harbor task folders" cell now reads "Not validated", the wordingmainuses for Copilot, so the column uses one term for a harness not yet run on a task folder.The
agentic_if_realworldtest fix pushed to this branch inf80584fb9is also inmain; after the merge those files matchmain.Validation on a Linux workstation:
responses_api_agents/openhands_agent/tests,tests/unit_tests/tooling,tests/unit_tests/agents,tests/unit_tests/configandtests/unit_tests/core: 2233 passed, 6 skipped, 1 failed. The failure istest_update_env_list.py::test_readme_hook_generates_once_without_filenames_and_is_idempotent, which needsgit ls-files --deduplicateand fails only because that machine's git 2.25 lacks it. Rollouts: none; the adapter is unchanged.Third merge with
main(2026-11-10)1558ce3a7 merges
mainat3de859110.main's #5946 splittest_add_legacy_agent_environment_servers.pyinto severaltest_agent_environment_*.pyfiles, which conflicted with the two OpenHands migration tests this PR added there. The merge keepsmain's split and moves both tests intotest_agent_environment_default_configs.py, next to the Claude Code test they followed before. Their content is unchanged. The PR had left the merge queue because of this conflict.Validation on a Linux workstation:
responses_api_agents/openhands_agent/tests,tests/unit_tests/agents,tests/unit_tests/configandtests/unit_tests/toolingall passed excepttest_update_env_list.py::test_readme_hook_generates_once_without_filenames_and_is_idempotent, which needsgit ls-files --deduplicateand that machine's git 2.25 lacks it. The PR and the merge leave that test's files unchanged. Rollouts: none; the adapter is unchanged.Second merge with
main(2026-11-10)03b57040f merges
mainataf7e67ee8, with no conflicts and no change to the OpenHands files. CI's server suite atc165acb94failed inresources_servers/agentic_if_realworld: four resume tests raised "Resume configuration fingerprint mismatch" because the CI checkout was dirty.mainfixed that in #5909, which this merge brings in.Validation on a Linux workstation:
responses_api_agents/openhands_agent/tests,tests/unit_tests/agents,tests/unit_tests/configandtest_add_legacy_agent_environment_servers.py: 1137 passed, 5 skipped (noopenhands-sdkin that venv). Rollouts: none; the merge does not change the adapter.Merge with
main(2026-11-09)c165acb94 merges
mainatf636596db, which added a "Harbor task folders" column to the harness table inintegrate-existing-agents.mdx. OpenHands' cell there said "Not tested" (now "Not validated"; see the fourth merge): its runs so far went throughsingle_agent_turn, never a Harbor task folder.Validation on a Linux workstation:
responses_api_agents/openhands_agent/tests: 131 passed, 5 skipped (that venv has noopenhands-sdk).tests/unit_tests/agents,test_fern_docs_links.pyand the seven repo-level suites listed under309a6412bbelow: all passed. 11 tests first failed because of how the test copy was set up (no git checkout, nouvonPATH, nocloudpickle); after fixing that, their 4 files passed again (50 passed).OpenHands' own model retries off (2026-11-09)
1aeb68f1e always hands OpenHands
num_retries: 0. A config that setsnum_retries,retry_min_wait,retry_max_waitorretry_multiplierinllm_settingsnow fails validation, and the shipped config no longer setsnum_retries: 5. OpenHands SDK 1.59.0 retries a model call on HTTP 408, 409, 429 and 5xx, and on any LiteLLMRateLimitError. LiteLLM 1.105.7 raises that error for any failure whose text mentions a rate limit or reads "Request too large", whatever its status. So a 409, a 413, or a 400 that mentions a rate limit was sent up to five times. Each model call is now sent once, and the Model Server's retries handle transient failures.Validation at
1aeb68f1e:openhands-sdkinstalled, passedresponses_api_agents/openhands_agent/tests. That includes the four new stub-server cases: a 409, a 400 that mentions a rate limit, a 413 "Request too large" and a 503 each reach the server exactly once. Locally, without the SDK: 131 passed, 5 skipped.network_access(2026-11-07)b2cc751ac adds
network_access(inherit,model_only,model_and_tools) like the other session harnesses, after mergingmainfor the sharedrestrict_sandbox_network(6323b9854). It limits an agent-owned OpenSandbox sandbox's egress. OpenHands keeps no tool grants, so both restricted values open only the Model Server's host. The Agent Server uploads the runtime, so setup needs no sandbox network. The defaultinheritleaves behavior unchanged.The following are final 422 seed refusals: a value other than
inheritwith a borrowed sandbox, a provider other than OpenSandbox, or an explicitsandbox_config.provider_options.network_policyas well. The provider is closed before any sandbox exists.Validation at
b2cc751ac(macOS, Python 3.13.14):responses_api_agents/openhands_agent/tests: 127 passed, 1 skipped. Undoing each part makes its new test fail: the borrowed-sandbox refusal, the restriction itself, and the provider close.309a6412bbelow: 306 passed and 3 failed. All 3 failures arecli/test_component_compatibility.py::test_parent_only_provider_and_differing_pins_are_installed_without_lock_mutation, whose code is identical tomain. My local uv 0.8.18 cannot parsemain's[tool.uv] exclude-dependencies.pre-commit run --fileson the four changed files: passed.Latest repair: c6f3d0a22. Cross-checked the commented case families across #5546, #5537, #5543, #5540, #5082, #5003, #5654 and #5650.
Preserve the original setup failure and retain provider wait failures alongside confirmed harness deadlines, including close replay. Preserve unknown cached/reasoning token details as null with explicit gaps: SDK-normalized zeros cannot establish measurement provenance. Aggregate usage and raw SDK statistics remain available.
Validation on the Linux workstation, with the locked component environment and final source hashes verified:
python -m pytest responses_api_agents/openhands_agent/tests -q -o addopts=: 122 passed. Targeted new regressions reproduced failures against the pre-repair production sources.pre-commit run --files <files changed by this repair>: passed; this was a scoped run.nvidia/nemotron-3.5-super-vl-120b-a12b, temperature 0, top_p 1, max_tokens 4096, thinking disabled, 180-second activation budget, agent-owned Dockerdebian:bookworm-slim. Responsecompleted, reward1.0,mask_sample=false. Adapter cleanup left no containers and required no fallback container removal.This one-row smoke is runtime/verification evidence; it does not qualify a benchmark pairing or establish strict harness conformance. The new head's reported lightweight GitHub checks pass; the
requestcheck is skipped, so full behavioral CI is not established by that status.What does this PR do?
Adds
responses_api_agents/openhands_agent, an agent-session adapter for the OpenHands Software Agent SDK. OpenHands runs headless inside the task sandbox of asingle_agent_turnEnvironment Server, likeclaude_code_agentandcodex_agent, and every model call goes to Gym's Model Server, including the condenser's summary calls./ng-rollout/<key>/v1/responsesruns one OpenHands conversation, and close confirms the harness stopped, copies its artifacts once, removes the session directory and returns an observation bundle. One activation per session: identical retries join it, and a different body or a mismatched rollout gets 409. Rollout stop is supported; a stop before the harness launches is graded instead of failing the activation. There is no host path and no/run; both a sessionless request and/runget 422.sandbox_accessnorsandbox_provider, a missingmodel_server, a workdir that is relative or overlaps the adapter's directories, a loopback Model Server URL for a remote sandbox, and anetwork_accessthe sandbox cannot enforce.model_serveris required. An agent-owned sandbox gets a TTL and provider metadata, and its misconfiguration also gets 422.openhands-sdkandopenhands-tools1.59.0, pinned in the adapter'spyproject.tomlanduv.lock. The task image's Python is never used. Gym'sSandboxPythonRuntimebuilds the runtime on the Agent Server host withuv: a pinned python-build-standalone CPython 3.13.14 plus the OpenHands packages for the sandbox's platform, at the versions the lock pins.func-timeout, which publishes only an sdist, is pinned by URL. The first build for each glibc level is cached under Gym'scache_dir, and later seeds upload the cached archives. The runtime is published atomically under/tmp/nemo-gym-openhands-runtime-<key>/and reused by later seeds in the same sandbox, so the sandbox needs no network,uvor Python of its own. The interpreter runs through anopenhands-gymlink, so a task'spkill python3cannot stop it.LLMwith modelopenai/<model>, the rollout-prefixed Model Server base URL, a placeholder key, andextra_headers: {x-session-id: <capture key>}. The default condenser summarizes with a copy of thatLLM(usage_id: condenser), so its calls reach the same URL.llm_settingsaccepts only an allowlist, because OpenHands silently ignores unknown names; settings that write files, call fallback models or stream are refused. The shipped config setsreasoning_effort: null, since OpenHands otherwise sendshigh, andapi_modeis pinned tochat. OpenHands' own model retries are off (num_retries: 0) and its retry settings are refused; the Model Server retries transient failures. Transport errors are classified before HTTP status codes.OH_PERSISTENCE_DIRmoves OpenHands'~/.openhandsstate into the session directory, and bash history goes there too; nothing is written under the task's home. The terminal uses OpenHands' subprocess backend, because the tmux backend starts a server that leaves the supervised process group. A sessionINPUTRCincludes the task's readline file and turns bracketed paste off; otherwise the 1.59.0 subprocess terminal leaves bash 5.1+'sESC[?2004hcodes in the tool output the model reads.finishtool's answer is also added as an assistant message.finishedmaps tocompleted. Iteration or budget limits, stuck detection, a rollout stop, a context-window error and Gym's deadline after a model call returned map toincompleteand are graded; anincompleteresponse carries nong_agent_outcome. The deadline before any model reply maps tofailedwithstop_reasontimeoutandunknown, because nothing shows that a model call was made; the outcome policy retriesunknownby default. Model errors map tofailedwithmodel_request_errorand the HTTP status the provider's error recorded, or withmodel_transport_error. Any other error that ends the run, including a model error that recorded no status, maps tofailedwithunknown. The runner records the ending error as its class and its explicit causes (raise ... from), each with any HTTP status. It does not record the error's text, which can hold a provider's response body; the traceback goes to the runner's stderr. Usage is reported only when every response the conversation used, condenser calls included, has a usage record.AgentInvocationwith per-callModelCallRefs from OpenHands' response IDs, aToolCallObservationper tool call (timing, status,sandbox_id), aContextCompactionObservationper condensation (its summary call is referenced only there, not by the invocation), aSandboxObservation, and gaps for missing evidence.openhands_agentjoinsAGENT_SESSION_AGENT_TYPES.scripts/add_legacy_agent_environment_servers.pynever puts a legacy relay in front of it, as for Stirrup, with tests. OpenHands rows are added to both harness tables in the agent-server docs. The server is a locked uv project (pyproject.tomlanduv.lock) with the same base as the other sandboxed agents plus the OpenHands pins.Capability level: Evaluation, with Observability records. Token IDs are not captured.
Validation
Unicode JSONL repair at
02c3ad1db9a354a81acdf780a6365cc117619006(November 6)JSONL parsing now splits only on LF, preserving literal U+0085, U+2028 and U+2029 in messages and tool arguments instead of dropping valid events. Twelve regression cases cover literal/escaped characters and LF/CRLF framing; the original source fails six.
Validation ran on the Linux workstation with Python 3.13.14 and locked component dependencies. All-files
pre-commit run --all-files, whitespace checks, and DCO passed; the workstation source tree matches this commit.gym env test +entrypoint=responses_api_agents/openhands_agent +should_validate_data=true ++skip_venv_if_present=true: 114 passed.One Reasoning Gym sages/fools task used an agent-owned
debian:bookworm-slimsandbox, NIMnvidia/nemotron-3.5-super-vl-120b-a12b, temperature 0, top_p 1, max_tokens 4096, thinking disabled, a 240-second budget, and the unchanged verifier. The response completed with original reward 1 and both captured model calls succeeded. Health is 1 passed, 0 flagged, 0 unobserved; profiling passed. Strict evidence is not_fulfilled only because this legacy Reasoning Gym result omitsevaluation_completed. Servers and sandbox were cleaned up. This is a bounded integration smoke, not full benchmark qualification. Earlier validation below remains tied to its recorded revisions. Full CI for this new head has not been triggered through a trust comment.At head
a55751f04:responses_api_agents/openhands_agent/tests: 101 passed, 1 skipped. The three deadline tests fail without07eac5f4a's outcome rule, and the no-events one also fails without itssandbox.pychange. Reverting eacha55751f04change fails its new test: following__context__fails the inherited-400 runner test, a status from the error class fails three missing-status cases, andmodel_transport_errorat a no-reply deadline fails the deadline test. The skipped test reads the OpenHands pins from an environment whereopenhands-sdkis installed; my local test venv doesn't have it.test_sandbox_runner.pyruns the real runner process against a stand-in SDK, including SIGTERM mid-run.pre-commit run --fileson the files0f33bee5d,678acc0c9,07eac5f4aanda55751f04change: passed.309a6412b, after merging currentmain(facc4ddec); the two later commits change only files in the adapter's directory:tests/unit_tests/test_session_contract_repo.py,tooling/test_add_legacy_agent_environment_servers.py,tooling/test_component_dependencies.py,cli/test_locked_env.py,cli/test_validate_server_configs.py,cli/test_component_compatibility.pyandorchestration/test_server_venv.py: 309 passed, none skipped.uv lock --check(uv 0.13.7) inresponses_api_agents/openhands_agent: passed (437 packages).pre-commit run --files <changed files>: passed.973f39ce9, before the review fixes, which change only the adapter's directory:tests/unit_tests/agents,tests/unit_tests/config, and the public-API, import-migration and import-linter coverage tests passed, except 3agents/test_outcome_policy.pyupload-evidence tests that fail withModuleNotFoundError: cloudpicklein my local venv and are unrelated to this branch.exit N, which ends OpenHands' persistent terminal session (outputexit, exit code -1). Driving the probes needs a conformance change in a separate PR.Rollouts
Terminal-Bench 2.1 at
7131e437with the Resources-owned Docker sandbox lent to the agent (Docker 28.1.1 on a workstation),nvidia/nemotron-3-ultra-550b-a55bon NVIDIA NIM through Gym's vLLM Model Server (uses_reasoning_parser: true),--concurrency 1,observability_enabled: true, OpenHandstimeout: 1200,max_iterations: 100,--allow-unsupported-pairing. Every server environment was built from its committeduv.lock(uv 0.13.7).gym eval health-check678acc0c907eac5f4a)0f33bee5d1d3df08dc1d3df08dcStrict evidence is
scripts/inspect_harness_conformance.py --require-sandbox. Every row hasevaluation_completed: true,mask_sample: falseand no failure, and the smoke-04 and smoke-05 health checks found no faulted model response. Response usage equals the captured input tokens on every row with a model call, and every captured call carries the invocation'sx-session-id.single_agent_turnclosed the agent session before verification on every rollout, every close carried the supervisor's exit code, and no labeled container was left after any run. No tool output in smoke-02 to smoke-05 has bracketed-paste codes.smoke-05 checks the tool-result fix: each of the 27 tool results that a later model call carried equals the text of the tool message in the captured request. The other 3 were each rollout's last tool result, which no captured call carried. smoke-05's rewards say nothing about the adapter, because the hosted model stopped answering during the run. Three rollouts reached the 1200 s deadline waiting for a model reply after their last tool call (exit code 143), and log-summary-date-ranges got no reply at all, so its record has no model call and fails the strict checks. At
678acc0c9that rollout was graded 0.0 as anincompletedeadline. Since07eac5f4athe same ending (the deadline, no model reply, no rollout stop) is afailedresponse, whichsingle_agent_turnretries instead of grading. Sincea55751f04its failure kind isunknownrather thanmodel_transport_error, because nothing shows a model call was made.test_a_deadline_before_any_model_reply_is_a_retried_failure_of_unknown_causereplays its shape. The other three 0.0 rows are still graded under the deadline-after-a-call rule: each got model replies before the Model Server stopped answering, and the adapter cannot tell that from a slow reply. After the run, an 8-token request to the same model timed out after 300 s through the Model Server and after 120 s sent directly, while the endpoint answered other requests at once. The tool-result fix changes what the adapter records, not what OpenHands sends the model, so smoke-04's rewards still describe the model-facing behavior.In smoke-04 the Agent Server built the sandbox runtime with
SandboxPythonRuntimeon its own host and uploaded it: once for regex-log's image (glibc 2.39) and once for the other three images (glibc 2.36). The cached archive was then reused. With uv's cache already warm from the Agent Server's own install, the two rollouts that built the runtime spent 85 s and 74 s outside the OpenHands run, and the other two spent 32 s and 45 s. That time also covers sandbox start and verification.The first smoke, smoke-01 on
cab997c1d, also graded 4/4 (1.0, 1.0, 0.0, 0.0) with health 4/4, and cancel-async-tasks ran one condensation, with all 53 calls captured. It found three defects, which1d3df08dcfixes: bracketed-paste codes in tool output (424 in one rollout), the condenser's summary call counted as a policy step (TE-9), and records withoutsandbox_id(TE-6).Known limits
678acc0c9, a recorded tool result held only the tool's output, without the notes OpenHands adds for the model; in smoke-04, 40 of 51 tool results differed from the model's tool message. smoke-02 to smoke-04 rows predate the fix.uvand access to PyPI and GitHub (python-build-standalone), or mirrors of them. The build is then cached.find / -name "python*"and used it to test its regex (smoke-02). The verifier never uses it.network_accessrestricts only an agent-owned OpenSandbox sandbox, and no restricted rollout has been run. With the defaultinherit, an owned sandbox's egress is open unless its provider limits it.Compatibility and benchmark impact
This is a new adapter; existing configs are unchanged.
openhands_agentis not added to any benchmark'sallowed_agents, so pairings need--allow-unsupported-pairing. The Terminal-Bench 2.1 full evaluation (8 repeats) is not done, so this PR doesn't claim TB2.1 support.🤖 Generated with Claude Code
CI repair — November 10
At
f80584fb90a9b433413b1d1cbcfe56df6262bbb0, isolate the synthetic HTTP resume test from source-fingerprint changes caused by concurrent CI workers. An explicit runtime-change assertion still verifies that resume rejects a changed runtime without modifying saved results or making new model/verifier calls. This repair is shared with the Copilot and Droid CI fixes.Workstation validation of this exact source tree: 13 HTTP resume/recovery and runtime-fingerprint tests passed; full
pre-commit run --all-filespassed using Python 3.13 hook environments. Model rollout: N/A, test-only change. No separate issue is needed for this CI repair.Documentation integration repair — November 11
Source
a178dc7a8847481e4d4571b8fe3dec8b0fce7338integrates main65aca7b6b7383d5070a26e45ec54d3c3a7411269. Keep OpenHands alongside main's corrected token-capture documentation and Goose. Align the branch-only OpenHands lockfile with main's OpenAI SDK 2.45.0 pin; only its constraint, package version, archive and wheel metadata change. OpenHands runtime and tests are unchanged. No separate issue is needed for this focused integration repair.Exact-tree Linux workstation validation:
python -m pytest responses_api_agents/openhands_agent/tests -q -o addopts=— 136 passed.python -m pytest tests/unit_tests/config/test_global_config.py::TestComposeUnboundAgent::test_agent_session_agent_types_match_the_agent_apps -q -o addopts=— 1 passed.python -m pytest tests/unit_tests/tooling/test_agent_environment_default_configs.py tests/unit_tests/tooling/test_agent_environment_session_templates.py -k 'openhands or goose' -q -o addopts=— 5 passed.python tests/unit_tests/test_fern_docs_links.py— 29 passed.pre-commit run --all-files— passed using pre-commit 4.3.0, compatible with the workstation's Git. The newer executable stopped before hooks because Git lacksls-files --deduplicate; no source or lock change was made for that tooling limitation.cd fern && npm run check— zero errors; authenticated missing-redirect check skipped because no Fern credential was available. No redirects changed.Independent source review found no blockers. New model rollout: N/A for this documentation conflict and dependency-lock alignment; historical model evidence remains pinned to its earlier revision. Fresh CI was requested at the exact new source; see current checks.
Completed CI at
a178dc7a8847481e4d4571b8fe3dec8b0fce7338: CICD NeMo Gym and release rehearsal passed. Lint and DCO passed.