Fix: browser_vision unconditionally passes --full, producing unreadable screenshots on long pages (#19620) - #19765
Open
umeshchandra-rao wants to merge 1 commit into
Conversation
Collaborator
Collaborator
Collaborator
|
Duplicate of #19647 |
This was referenced May 5, 2026
teknium1
reviewed
Jul 12, 2026
teknium1
left a comment
Contributor
There was a problem hiding this comment.
Thanks for isolating a real browser-vision failure: current main still unconditionally appends --full on the normal screenshot path (tools/browser_tool.py:4017-4022).
Problems
- The new parameter is not agent-callable. Current schema exposes only
questionandannotate(tools/browser_tool.py:1933-1944), and the registry forwards only those fields (tools/browser_tool.py:4792). - Current
browser_visionalso has Camofox delegation (tools/browser_tool.py:3911-3913) and a Lightpanda-to-Chrome fallback with separate screenshot args (tools/browser_tool.py:3963-3968); this old-context patch does not define or testfull_pagebehavior for them. - The PR adds no regression coverage; existing argument coverage is in
tests/tools/test_browser_console.py:305-344.
Suggested changes
- Add and forward
full_pagethrough the schema and registry, then cover normal, Lightpanda, and Camofox behavior with current-path tests.
Automated hermes-sweeper review.
| @@ -2344,7 +2344,7 @@ def browser_get_images(task_id: Optional[str] = None) -> str: | |||
| }, ensure_ascii=False) | |||
Contributor
There was a problem hiding this comment.
This adds a Python-only parameter, but the model-facing schema and registry handler are not updated. full_page must be added to BROWSER_TOOL_SCHEMAS and forwarded by the browser_vision registration; otherwise tool calls cannot request viewport-only capture.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The
browser_visionfunction unconditionally took full-page screenshots. On long web pages, this produced excessively large and unreadable images, causing vision analysis to fail. This change introduces afull_pageparameter to the function, which defaults toTrueto maintain backward compatibility. The screenshot command now only includes the--fullflag whenfull_pageisTrue, enabling callers to request a viewport-only screenshot.Changes
tools/browser_tool.py:full_page: bool = Trueparameter to thebrowser_visionfunction signature.--fullflag to the screenshot command based on thefull_pageparameter.How to verify
browser_visionon a long web page withfull_page=False.browser_visionwithfull_page=True(or without the argument).Opened via Open Issue Fixer · AI-assisted. Please review carefully before merging.