distinctify failed scrapes due to no url (#2977)
This commit is contained in:
@@ -264,10 +264,16 @@ class EmptyScrapePage(SkyvernException):
|
||||
|
||||
|
||||
class ScrapingFailed(SkyvernException):
|
||||
def __init__(self) -> None:
|
||||
def __init__(self, *, reason: str | None = None) -> None:
|
||||
self.reason = reason
|
||||
super().__init__("Scraping failed.")
|
||||
|
||||
|
||||
class ScrapingFailedNoUrl(ScrapingFailed):
|
||||
def __init__(self) -> None:
|
||||
super().__init__(reason="A URL is missing. Please ensure there is a URL for Skyvern to work with.")
|
||||
|
||||
|
||||
class WorkflowRunContextNotInitialized(SkyvernException):
|
||||
def __init__(self, workflow_run_id: str) -> None:
|
||||
super().__init__(f"WorkflowRunContext not initialized for workflow run {workflow_run_id}")
|
||||
|
||||
Reference in New Issue
Block a user