verification code V2 - support verification code of multiple separate single character input fields (#683)
Co-authored-by: Shuchang Zheng <wintonzheng0325@gmail.com>
This commit is contained in:
@@ -10,7 +10,7 @@ import structlog
|
||||
from deprecation import deprecated
|
||||
from playwright.async_api import FileChooser, Locator, Page, TimeoutError
|
||||
|
||||
from skyvern.constants import REPO_ROOT_DIR, VERIFICATION_CODE_PLACEHOLDER, VERIFICATION_CODE_POLLING_TIMEOUT_MINS
|
||||
from skyvern.constants import REPO_ROOT_DIR, VERIFICATION_CODE_POLLING_TIMEOUT_MINS
|
||||
from skyvern.exceptions import (
|
||||
EmptySelect,
|
||||
ErrFoundSelectableElement,
|
||||
@@ -711,13 +711,6 @@ async def get_actual_value_of_parameter_if_secret(task: Task, parameter: str) ->
|
||||
|
||||
This is only used for InputTextAction, UploadFileAction, and ClickAction (if it has a file_url).
|
||||
"""
|
||||
if task.totp_verification_url and task.organization_id and VERIFICATION_CODE_PLACEHOLDER == parameter:
|
||||
# if parameter is the secret code in the navigation playload,
|
||||
# fetch the real verification from totp_verification_url
|
||||
# do polling every 10 seconds to fetch the verification code
|
||||
verification_code = await poll_verification_code(task.task_id, task.organization_id, task.totp_verification_url)
|
||||
return verification_code
|
||||
|
||||
if task.workflow_run_id is None:
|
||||
return parameter
|
||||
|
||||
|
||||
Reference in New Issue
Block a user