runs logs
Retrieve log bytes for a run or a task
Synopsis
Description
Retrieve log bytes for a run or a task and stream to the console. The content of Run level logs are engine and environment dependent and may not always be present.Task-level logs often contain the log output generated from the execution of the task itself and can be helpful for debugging a task.
Examples
Retrieve the workflow level stdout
logs for a given run and print it to the console.
You can easily switch to streaming the stderr logs instead of the stderr
.
If you would like to retrieve the logs for a given task, you first will need the task_id
. The task_id
can be retrieved using the runs tasks list command:
Once you have the task_id
, you can then use it in the logs command to retrieve the task level logs.
Positional Flags
[RUN_ID|LOGURL]
[RUN_ID|LOGURL]
Flags
--max-bytes
=NUMBER
--max-bytes
=NUMBER
Limit the number of bytes to retrieve from the log stream.
--offset
=NUMBER
--offset
=NUMBER
Skip over N
bytes in the log-stream, allowing you to jump into a random part of the log.
--log-type
=LOG_TYPE
--log-type
=LOG_TYPE
Toggle whether to write the associated stderr
or stdout
to the output. If this value flag is not specified the default is stdout
.
Valid choices: stdout
, stderr
--task-id
=TASK_ID
--task-id
=TASK_ID
If specified, retrieve the logs for a given task within a run. The task_id
can be retrieved from the runs tasks list command.
--output
=PATH
--output
=PATH
If specified, attempt to write the stderr or stdout logs to the given file path. If the file exists, the command will exit without overwriting it.
In order to get the logs for a specific task, you can first use the runs tasks list
command to retrieve a list of task IDs. tasks?
Last updated