Skip to content

[WIP] Reduce CLI flags#13

Draft
TomSellers wants to merge 1 commit intomainfrom
reduce_command_line_flags
Draft

[WIP] Reduce CLI flags#13
TomSellers wants to merge 1 commit intomainfrom
reduce_command_line_flags

Conversation

@TomSellers
Copy link
Copy Markdown

@TomSellers TomSellers commented Mar 19, 2026

The goal of this PR is reduce the number of CLI flags we're passing to Chrome with the goal of trying to avoid certain CLI limits on Windows. This might help address the following on WIndows:

time="2026-03-19T08:03:20-05:00" level=error msg="failed to initialize chromedp screenshots: failed to start chromium browser: launcher failed to get the debug url from chromium: in\core\browser\account_reconcilor.cc:179] AccountReconcilor::Initialize
[11152:13960:0319/080303.615:VERBOSE1:components\signin\core\browser\account_reconcilor.cc:230] AccountReconcilor::RegisterWithContentSettings
[11152:13960:0319/080303.615:VERBOSE1:components\signin\core\browser\account_reconcilor.cc:253] AccountReconcilor::RegisterWithIdentityManager
[11152:13860:0319/080303.615:VERBOSE1:net\disk_cache\simple\simple_index_file.cc:609] Simple Cache Index is being restored from disk.

DevTools remote debugging requires a non-default data directory. Specify this using --user-data-dir.
[11152:13960:0319/080303.615:WARNING:chrome\browser\chrome_browser_main_win.cc:787] Command line too long for RegisterApplicationRestart:  --allow-chrome-scheme-url --allow-pre-commit-input --bwsi --disable-background-networking --disable-background-timer-throttling --disable-backgrounding-occluded-windows --disable-breakpad --disable-client-side-phishing-detection --disable-component-extensions-with-background-pages --disable-component-update --disable-crash-reporter --disable-default-apps --disable-dev-shm-usage --disable-features=site-per-process,TranslateUI,OptimizationGuideModelDownloading,OptimizationHintsFetching,OptimizationTargetPrediction,OptimizationHints --disable-gpu --disable-hang-monitor --disable-infobars --disable-ipc-flooding-protection --disable-notifications --disable-plugins --disable-popup-blocking --disable-prompt-on-repost --disable-renderer-backgrounding --disable-search-engine-choice-screen --disable-site-isolation-trials --disable-sync --disable-translate --disable-web-security --enable-automation --enable-features=NetworkService,NetworkServiceInProcess --enable-logging=stderr --export-tagged-pdf --force-color-profile=srgb --generate-pdf-document-outline --headless --hide-scrollbars --ignore-certificate-errors --log-level=1 --metrics-recording-only --mute-audio --no-crashpad --no-default-browser-check --no-first-run --no-startup-window --noerrdialogs --password-store=basic --remote-debugging-port=0 --safebrowsing-disable-auto-update --use-mock-keychain --user-agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36 runZero/3" --user-data-dir=C:/Windows/SystemTemp/runzero-chrome-49169229/go-rod-launcher-3155627792 --v=1 --window-size=1920,1080 --restore-last-session --restart

The changes here assume the environment is running a version of Chrome released in the last 5 years.

I'd probably pair this with ensuring that the --user-data-dir= is early in the list.

Note, enabling "Hide whitespace" during the review will make the actual changes easier to spot

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant