Skip to content

Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.

turn selector mandatory and timeout optional with a default wait time of 10 seconds

jersobh8db1230b9d74
diff --git a/browser_use/controller/views.py b/browser_use/controller/views.py
index c2a62a9c9..c812a5e11 100644
--- a/browser_use/controller/views.py
+++ b/browser_use/controller/views.py
@@ -13,8 +13,8 @@ class GoToUrlAction(BaseModel):
class WaitForElementAction(BaseModel):
- selector: Optional[str] = None
- timeout: int # Timeout in milliseconds
+ selector: str
+ timeout: Optional[int] = 10000 # Timeout in milliseconds
class ClickElementAction(BaseModel):
index: int