snowflake.core.task.dagv1.DAGRun¶
- class snowflake.core.task.dagv1.DAGRun¶
Bases:
object
Contains the history of a task graph run in Snowflake.
From https://docs.snowflake.com/en/sql-reference/functions/current_task_graphs#output, but tweaked a little bit to fit into task graph context.
Attributes
- dag_name: str¶
Name of the root task and the task graph.
- database_name: str¶
Name of the database that contains the graph.
- schema_name: str¶
Name of the schema that contains the graph.
- state: str¶
state of the task graph run. One of [“SCHEDULED”, “EXECUTING”, “SUCCEEDED”, “FAILED”, “CANCELLED”].
- first_error_task_name: str | None¶
Name of the first task in the graph that returned an error.
- first_error_code: int | None¶
Error code of the error returned by the task named in
first_error_task_name
.
- first_error_message: str | None¶
Error message of the error returned by the task named in
first_error_task_name
.
- scheduled_time: datetime | None¶
Time when the root task was scheduled to start running.
- query_start_time: datetime | None¶
Time when the query in the root task definition started to run.
- next_scheduled_time: datetime¶
- run_id: int¶
epoch time in milliseconds of the root task’s original scheduled start time.
- graph_version: int¶
Integer identifying the version of the task graph that was run, or is scheduled to be run.
Methods
- __init__()¶