In shared-overwrite/.github/actions/setup/action.yml, MT code sync step can hang while using apt-get to install missing dependencies (like inkscape, libxml2-utils...).
Sometimes it's just very slow.
https://github.com/mtransitapps/ca-montreal-amt-train-android/actions/runs/24217828886/job/70702433276#step:3:1428
How can we prevent it? Can we use a max duration for the step and retry once automatically?
Is this a regular issue on GitHub-hosted runners?
https://github.com/mtransitapps/commons/blob/master/shared-overwrite/.github/actions/setup/action.yml
https://github.com/mtransitapps/commons/blob/master/commons.sh#L335
|
function requireCommand() { |
|
local cmd=$1 |
|
local pkg=${2:-$cmd} # Default to cmd if pkg is not provided |
|
command -v "$cmd" >/dev/null 2>&1 || (sudo apt-get update && sudo apt-get install -y "$pkg") |
|
} |
Maybe we could add a step before ./commons/code_sync.sh in the setup action responsible for pre-installing all missing dependencies because these packages will be needed for all repo soon anyway.
Current apt packages needed:
libxml2-utils
jq
inkscape
imagemagick
In
shared-overwrite/.github/actions/setup/action.yml,MT code syncstep can hang while usingapt-getto install missing dependencies (likeinkscape,libxml2-utils...).Sometimes it's just very slow.
https://github.com/mtransitapps/ca-montreal-amt-train-android/actions/runs/24217828886/job/70702433276#step:3:1428
How can we prevent it? Can we use a max duration for the step and retry once automatically?
Is this a regular issue on GitHub-hosted runners?
https://github.com/mtransitapps/commons/blob/master/shared-overwrite/.github/actions/setup/action.yml
https://github.com/mtransitapps/commons/blob/master/commons.sh#L335
commons/commons.sh
Lines 335 to 339 in 94162c3
Maybe we could add a step before
./commons/code_sync.shin thesetupaction responsible for pre-installing all missing dependencies because these packages will be needed for all repo soon anyway.Current
aptpackages needed:libxml2-utilsjqinkscapeimagemagick