Repository navigation
ci(e2e): stop e2e legs timing out on EBI when the data cache is empty #301
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -499,6 +499,21 @@ trap 'kill "$LOW_PID" 2> /dev/null || true' EXIT | |
| # a run that saves the cache) a case's cached files are deleted after it, | ||
| # to give the disk back. | ||
| DATA_CACHE=${E2E_DATA_CACHE:-} | ||
| # E2E_DATA_MIRROR, when set, is a folder URL (a GitHub release) holding copies | ||
| # of these pinned files under their own names. Each file is tried there once | ||
| # first, then at its source. EBI's 1000 Genomes hosts swing between a few KB/s | ||
| # and MB/s from one request to the next, and a leg with no Actions cache could | ||
| # spend its whole time limit on one download. The pin checks both copies the | ||
| # same way, so the mirror can only save time, never change what a case reads. | ||
| # mfetch URL DEST KIND SUM: fetch from the mirror, then from URL. Called | ||
| # inside data_fetch, after it sources scripts/lib/common.sh for fetch. | ||
| mfetch() { | ||
| if [ -n "${E2E_DATA_MIRROR:-}" ]; then | ||
| FETCH_TRIES=1 fetch "${E2E_DATA_MIRROR%/}/${1##*/}" "$2" "$3" "$4" 2> /dev/null && return 0 | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| echo "Data cache: ${1##*/} not on the mirror; downloading it from its source" | ||
| fi | ||
| fetch "$@" | ||
| } | ||
| # data_fetch NAME: fills E2E_DATA_CACHE/NAME with what is missing, in a | ||
| # subshell that sources scripts/lib/common.sh for fetch and the pins. | ||
| data_fetch() ( | ||
|
|
@@ -512,21 +527,21 @@ data_fetch() ( | |
| mocha) | ||
| m="${d}/manifest.txt" | ||
| { [ -s "$m" ] && [ "$(_digest sha256 "$m")" = "$MOCHA_PANEL_MANIFEST_SHA256" ]; } \ | ||
| || fetch "${MOCHA_PANEL_URL}/20220804_manifest.txt" "$m" sha256 "$MOCHA_PANEL_MANIFEST_SHA256" || exit 1 | ||
| || mfetch "${MOCHA_PANEL_URL}/20220804_manifest.txt" "$m" sha256 "$MOCHA_PANEL_MANIFEST_SHA256" || exit 1 | ||
| # mocha-1 cuts the panel to the fixture's chr20 slice. | ||
| f=1kGP_high_coverage_Illumina.chr20.filtered.SNV_INDEL_SV_phased_panel.vcf.gz | ||
| for e in "" .tbi; do | ||
| md5=$(awk -v n="${f}${e}" '$1 == n {print $2}' "$m") | ||
| [ -n "$md5" ] || { echo "ERROR: ${f}${e} is not in the panel manifest" >&2; exit 1; } | ||
| [ -s "${d}/raw/${f}${e}" ] && [ "$(_digest md5 "${d}/raw/${f}${e}")" = "$md5" ] && continue | ||
| fetch "${MOCHA_PANEL_URL}/${f}${e}" "${d}/raw/${f}${e}" md5 "$md5" || exit 1 | ||
| mfetch "${MOCHA_PANEL_URL}/${f}${e}" "${d}/raw/${f}${e}" md5 "$md5" || exit 1 | ||
| done ;; | ||
| archaic) | ||
| url=$(sed -n 's/^ARCHAIC_1KG_SITES_URL=//p' "${REPO}/scripts/setup.sh") | ||
| [ -n "$url" ] || { echo "ERROR: no ARCHAIC_1KG_SITES_URL line in scripts/setup.sh" >&2; exit 1; } | ||
| s="${d}/1kg_sites.vcf.gz" | ||
| [ -s "$s" ] && [ "$(_digest md5 "$s")" = "$ARCHAIC_1KG_SITES_MD5" ] && exit 0 | ||
| fetch "$url" "$s" md5 "$ARCHAIC_1KG_SITES_MD5" || exit 1 ;; | ||
| mfetch "$url" "$s" md5 "$ARCHAIC_1KG_SITES_MD5" || exit 1 ;; | ||
| hla) | ||
| # The files install_data_file writes, made by install_data_file itself | ||
| # with the entry as GENOME_DIR: hla.dat of both releases (md5 from | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Script executed:
rg -n 'e2e-data-1|E2E_DATA_MIRROR|20220804_manifest|ARCHAIC_1KG_SITES_URL|MOCHA_PANEL_URL|release upload' .github scripts docs versions.envRepository: GeiserX/OwnGenome
Length of output: 5882
Script executed:
Repository: GeiserX/OwnGenome
Length of output: 41549
Script executed:
Repository: GeiserX/OwnGenome
Length of output: 26204
Publish the missing MoChA mirror assets.
The configured
e2e-data-1release contains only the archaic VCF andMD5SUMS. It lacks the MoChA manifest, VCF, and index. A coldmocha-1run therefore falls back to EBI and can spend the 240-minute shard limit on the original slow transfer. Upload all pinned MoChA assets and update them with pin changes.