Conversation
Co-authored-by: openhands <openhands@all-hands.dev>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
all-hands-bot
left a comment
There was a problem hiding this comment.
🟢 Good taste - Clean feature detection pattern with proper backward compatibility.
[IMPROVEMENT OPPORTUNITIES] (Optional)
Consider adding a test case for backward compatibility when available_tools is missing:
it("allows all tools when server does not provide available_tools metadata", async () => {
server.use(
http.get("/server_info", () =>
HttpResponse.json({
uptime: 0,
idle_time: 0,
version: "1.17.0",
// No available_tools field
}),
),
);
await OptionService.getConfig();
expect(isAgentServerToolAvailable("browser_tool_set")).toBe(true);
expect(isAgentServerToolAvailable("terminal")).toBe(true);
});This would explicitly verify the fallback behavior for older servers that don't advertise capabilities.
[RISK ASSESSMENT]
This is a clean infrastructure improvement that adds proper server capability detection. The change:
- Only gates tools based on actual server support
- Maintains full backward compatibility with older servers via sensible fallback (allow all tools when metadata is missing)
- Has good test coverage for the new gating behavior
- Makes no changes to agent behavior, prompts, or evaluation-sensitive code
The module-level cache pattern is appropriate for a frontend that connects to a single backend per session. Cache invalidation happens correctly on errors.
VERDICT:
✅ Worth merging: Solid implementation with proper fallback behavior. The optional test suggestion above would strengthen the backward compatibility coverage, but existing tests are sufficient.
KEY INSIGHT:
Elegant additive feature detection that degrades gracefully for older servers - new servers get fine-grained tool gating, old servers preserve existing env-flag behavior.
|
@OpenHands QA to confirm that this PR works with OpenHands/software-agent-sdk#3028 in the case that the browser is available or unavailable. |
|
I'm on it! neubig can track my progress at all-hands.dev |
Co-authored-by: openhands <openhands@all-hands.dev>
|
QA complete. I found one integration mismatch while checking against What I verified:
AI-generated PR update/comment by OpenHands on behalf of the user. |
|
Final summary: Completion status
New changes since my last summary
Conciseness check
|
Co-authored-by: openhands <openhands@all-hands.dev>
|
Follow-up update: per review, I removed the frontend fallback to Current behavior on this branch:
I re-ran:
AI-generated PR update/comment by OpenHands on behalf of the user. |
|
This still needs live testing. |
Summary
/server_infotool metadata during the compatibility probe and gate browser-tool requests onusable_toolsbrowser_tool_setwhen the env flag allows it and the connected server advertises browser supportmainVerification
npm testnpm run typechecknpm run buildDepends on OpenHands/software-agent-sdk#3028 for the
/server_info.usable_toolsmetadata. When the server does not advertise tool metadata, the frontend keeps the previous allow-all behavior.This PR was created by an AI agent (OpenHands) on behalf of the user.