fix(browser): use AGENT_BROWSER_ARGS instead of AGENT_BROWSER_CHROME_FLAGS - #24198
Open
ambition0802 wants to merge 1 commit into
Open
fix(browser): use AGENT_BROWSER_ARGS instead of AGENT_BROWSER_CHROME_FLAGS#24198ambition0802 wants to merge 1 commit into
ambition0802 wants to merge 1 commit into
Conversation
…FLAGS The browser tool was setting AGENT_BROWSER_CHROME_FLAGS when sandbox bypass was needed, but agent-browser only reads AGENT_BROWSER_ARGS. This caused the --no-sandbox injection to be a silent no-op on Ubuntu 23.10+ / AppArmor systems, resulting in "No usable sandbox" errors. Changes: - Rename AGENT_BROWSER_CHROME_FLAGS → AGENT_BROWSER_ARGS in _run_browser_command() - Add the same sandbox bypass logic to _run_chrome_fallback_command() which was missing it entirely - Update comments to reference issue NousResearch#23496 Fixes NousResearch#23496 Related: NousResearch#15765
Collaborator
This was referenced May 13, 2026
Contributor
|
Thanks for identifying the Problems
Suggested changes
Automated hermes-sweeper review. |
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.
Summary
The browser tool was setting
AGENT_BROWSER_CHROME_FLAGSwhen sandbox bypass was needed, butagent-browseronly readsAGENT_BROWSER_ARGS. This caused the--no-sandboxinjection to be a silent no-op on Ubuntu 23.10+ / AppArmor systems, resulting in "No usable sandbox" errors.Changes
Fixed env var name in
_run_browser_command():AGENT_BROWSER_CHROME_FLAGS→AGENT_BROWSER_ARGSAdded sandbox bypass to
_run_chrome_fallback_command():AGENT_BROWSER_ARGSinjectionbrowser fallback:)Root Cause
Commit 74c1b94 added sandbox bypass detection and wrote to
AGENT_BROWSER_CHROME_FLAGS, but theagent-browserCLI only consumesAGENT_BROWSER_ARGS. The env var mismatch meant the flags were never actually passed to Chromium on launch.Testing
agent-browserdocumented env varsAffected Systems
Fixes #23496
Related: #15765