Replies: 1 comment
-
|
The timeout-minutes counts from when the job starts, not when the steps start executing. The gap you are seeing is likely due to: 1. Queue time counts toward timeoutIf your self-hosted runner takes time to pick up the job (e.g., spinning up, waiting in queue), that time counts against the timeout. So if the job sits in queue for 6 minutes and your timeout is 8 minutes, your steps only get 2 minutes. 2. Setup steps are hiddenGitHub Actions runs setup steps before your visible steps:
These are not shown in the step timing breakdown but count toward the timeout. How to diagnoseLook at the job timeline:
Fix
steps:
- name: Build
timeout-minutes: 5 # per-step timeout
run: npm run build
The job-level timeout-minutes is working correctly - it is just measuring a wider window than the visible step durations suggest. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Problem
Sometimes the workflows are running into
timeout-minuteslimit and getting cancelledeven though the the total time for all steps didn't reach the timeout limit.
For example, the following workflow run was cancelled because it hit the
timeout-minutes: 8limit.However, the total time for all of the steps was only around ~
2minutes.Note: I'm using Actions Runner Controller for my workflow. I noticed that the timer for the job/run starts
immediately before the steps start running (sometimes it takes a few minutes for the first step to start).
Question
I'm suspecting that, the
timeout-minutesis using the initial queue start time for the job (maybe?) insteadof the time that passed from the first step.
How can I make the
timeout-minutesto use the total time for the steps instead of the job queue start?Beta Was this translation helpful? Give feedback.
All reactions