Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/workflows/desktop-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -957,7 +957,11 @@ jobs:
--clobber
# A successful HTTP response can still contain the previous CDN object.
# Retry content validation as well as transport failures after replacement.
for attempt in {1..12}; do
# GitHub's release CDN can take several minutes to converge after a
# clobber, so keep the failure bound at five minutes instead of
# treating a transient stale object as a failed release.
max_readback_attempts=60
for ((attempt = 1; attempt <= max_readback_attempts; attempt++)); do
if curl -fsSL --max-time 30 \
"https://github.com/${GITHUB_REPOSITORY}/releases/download/channel-v1-beta/latest-v1.json" \
-o channel-v1-beta.published.json && \
Expand All @@ -966,8 +970,8 @@ jobs:
echo "Beta channel manifest verified: ${CANDIDATE_VERSION}"
exit 0
fi
echo "Beta channel manifest is not ready (attempt ${attempt}/12)."
if [[ "${attempt}" -lt 12 ]]; then sleep 5; fi
echo "Beta channel manifest is not ready (attempt ${attempt}/${max_readback_attempts})."
if [[ "${attempt}" -lt "${max_readback_attempts}" ]]; then sleep 5; fi
done
echo "Beta channel manifest did not converge to ${CANDIDATE_VERSION}." >&2
exit 1
Expand Down
2 changes: 1 addition & 1 deletion scripts/check-github-config.test.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -1437,7 +1437,7 @@ fs.writeFileSync(output, content);
});
assert.equal(result.status, scenario === 'stale' ? 1 : 0, `${scenario}: ${result.stderr}`);
const requests = Number(readFileSync(path.join(cwd, 'requests'), 'utf8'));
assert.ok(requests > 1 && requests <= 12, `${scenario}: bounded content retries`);
assert.ok(requests > 1 && requests <= 60, `${scenario}: bounded content retries`);
if (scenario === 'stale') assert.match(result.stderr, /did not converge/);
}
});
Expand Down
Loading