-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Description
If I have the following code, it gives me error because it is not documented error in Raises, but it should document PlaywrightError instead of error
async def fill(self, text: str, time_wait: int = 0) -> None:
"""Write text into the fragment.
Args:
text: What we want to write.
time_wait: Time to wait for the action that executes those keys to complete. (Milliseconds)
Raises:
InvalidActionError: Fragment not support fill
"""
try:
await self.__fragment.fill(text)
await asyncio.sleep(time_wait / 1000)
except PlaywrightError as error:
if "Element is not an <input>, <textarea> or [contenteditable] element" in error.message:
raise InvalidActionError(self._css_query, "fill")
raise error
GabrielOctavianPopa
Metadata
Metadata
Assignees
Labels
No labels