View Task Logs
Applicable Scenarios: When a pipeline task fails or behaves abnormally, you need to view the complete log output step by step to locate specific error lines, command return codes, or environment issues.
Configuration Description
View Access Point
- Enter the target run details page (see 1.1).
- Click on the target job card to expand the step timeline.
- Click on a step line, and the right panel displays the full standard output and standard error of that step.
Log Structure
The logs for each job are organized in step order:
── Job: compile ({ubuntu-24,x64,small})
├── Step 1: Checkout repository ← run: git checkout
├── Step 2: Set up toolchain ← uses: action-setup-toolchain
├── Step 3: Run build command ← run: make build
└── Post: Clean up workspace ← post processing
Each log line has a prefix with a timestamp and step number, making it easier to track the timeline.
Log Search and Collapse
- Collapse: Long output steps are collapsed by default, click to expand and view the full content.
- Search: Enter keywords (such as
Error,fatal,FATAL) at the top of the log panel, and the system highlights matching lines. - Download: Click the "Download Log" button in the top right corner to get the complete log file for this job.
Context Variables in Logs
Logs may contain expanded results of AtomGit Action context variables, for example:
steps:
- run: echo "Repo is ${{ atomgit.repository }}"
- run: echo "Actor is ${{ atomgit.actor }}"
- run: echo "Event is ${{ atomgit.event_name }}"
The atomgit context expands to actual values in the logs, making it easy to confirm whether the trigger information is correct.
System Variables ATOMGIT_*
In addition to ${{ }} expressions, the Runner environment also injects ATOMGIT_* system environment variables, which can be directly viewed in the logs:
| Variable Name | Description |
|---|---|
ATOMGIT_REPOSITORY | Full name of the repository (owner/repo) |
ATOMGIT_EVENT_NAME | Type of triggering event |
ATOMGIT_REF | Triggered reference (branch/tag) |
ATOMGIT_SHA | Triggered commit SHA |
ATOMGIT_ACTOR | Triggering user |
ATOMGIT_TOKEN | Automatically generated session Token |
ATOMGIT_RUN_ID | Unique ID of the run |
ATOMGIT_RUN_NUMBER | Run number |
steps:
- run: |
echo "System vars:"
echo "Repo = $ATOMGIT_REPOSITORY"
echo "SHA = $ATOMGIT_SHA"
Common Issues
Q: The log contains *** to mask content, how to view the original value?
A: Log lines containing Secret values are automatically masked as ***, which is a security mechanism and the original value cannot be viewed in the interface. Please confirm if the Secret is correctly configured on the project/organization Settings → Secrets page.
Q: Some step logs are empty, what is the reason?
A: Possible reasons include: (1) the step uses uses to reference an Action, and the Action itself has no output; (2) the command is redirected with > /dev/null; (3) the step timed out during setup and was killed, so the logs were not fully written.
Q: The downloaded log file has encoding issues?
A: The downloaded log is a UTF-8 encoded text file. If your local tool opens it by default in GBK, it may cause garbled text. Please switch the editor's encoding to UTF-8.