mirror of
https://github.com/browser-use/web-ui.git
synced 2026-03-22 11:17:17 +08:00
remove cdp url in webui
This commit is contained in:
5
webui.py
5
webui.py
@@ -316,7 +316,6 @@ async def run_org_agent(
|
||||
config=BrowserContextConfig(
|
||||
trace_path=save_trace_path if save_trace_path else None,
|
||||
save_recording_path=save_recording_path if save_recording_path else None,
|
||||
cdp_url=cdp_url,
|
||||
no_viewport=False,
|
||||
browser_window_size=BrowserContextWindowSize(
|
||||
width=window_w, height=window_h
|
||||
@@ -407,7 +406,7 @@ async def run_custom_agent(
|
||||
|
||||
# Initialize global browser if needed
|
||||
#if chrome_cdp not empty string nor None
|
||||
if ((_global_browser is None) or (cdp_url and cdp_url != "" and cdp_url != None)) :
|
||||
if (_global_browser is None) or (cdp_url and cdp_url != "" and cdp_url != None):
|
||||
_global_browser = CustomBrowser(
|
||||
config=BrowserConfig(
|
||||
headless=headless,
|
||||
@@ -418,7 +417,7 @@ async def run_custom_agent(
|
||||
)
|
||||
)
|
||||
|
||||
if (_global_browser_context is None or (chrome_cdp and cdp_url != "" and cdp_url != None)):
|
||||
if _global_browser_context is None or (chrome_cdp and cdp_url != "" and cdp_url != None):
|
||||
_global_browser_context = await _global_browser.new_context(
|
||||
config=BrowserContextConfig(
|
||||
trace_path=save_trace_path if save_trace_path else None,
|
||||
|
||||
Reference in New Issue
Block a user