Automate browser based workflows with AI
Python aiapiautomationbrowserbrowser-automationcomputergptllmplaywrightpowerautomatepuppeteerpythonrpaseleniumvisionworkflow
fix element_id type for action and web action + add unit tests for actions (#424)
Kerem Yilmaz92f72b27a5a9
diff --git a/skyvern/webeye/actions/actions.py b/skyvern/webeye/actions/actions.pyindex 119fe0f93..d1aadd7c1 100644--- a/skyvern/webeye/actions/actions.py+++ b/skyvern/webeye/actions/actions.py@@ -1,5 +1,5 @@from enum import StrEnum-from typing import Any, Dict+from typing import Annotated, Any, Dictimport structlogfrom deprecation import deprecated@@ -47,7 +47,7 @@ class Action(BaseModel):action_type: ActionTypedescription: str | None = Nonereasoning: str | None = None- element_id: int | str | None = None+ element_id: Annotated[str, Field(coerce_numbers_to_str=True)] | None = None# DecisiveAction (CompleteAction, TerminateAction) fieldserrors: list[UserDefinedError] | None = None@@ -64,7 +64,7 @@ class Action(BaseModel):class WebAction(Action):- element_id: int | str+ element_id: Annotated[str, Field(coerce_numbers_to_str=True)]class DecisiveAction(Action):