rjgoyln opened a new pull request, #72382: URL: https://github.com/apache/airflow/pull/72382
## Summary `prek install-hooks` downloads the toolchains its hooks need, and prek does not retry, so a transient 5xx from a download host fails the job before it has done any work. Two jobs in [run 33525573182](https://github.com/apache/airflow/actions/runs/33525573182) died this way while the other 48 passed: ``` error: Failed to install hook `go-mod-tidy` caused by: Failed to download file from https://go.dev/dl/go1.25.0.linux-amd64.tar.gz caused by: HTTP status server error (500 Internal Server Error) for url (https://go.dev/dl/go1.25.0.linux-amd64.tar.gz) ``` Only jobs reaching this step before the prek cache tarball has been written are exposed; every later job restores the toolchains from cache and makes no outbound request at all. The failure therefore lands on any PR at random, unrelated to its contents. The cache restore step in this action is already pinned to a revision that retries its own download, which left hook installation as the last unguarded external dependency here. Upgrading prek is not an alternative: its download path is byte-identical between the pinned 0.4.14 and the current 0.5.1, and the Go installer still hardcodes the `go.dev` URL. ## Tests Reproduced against a stand-in `go.dev` — a CONNECT proxy trusted through `SSL_CERT_FILE`, returning 500 for the pinned Go tarball and the real bytes on success so that prek's checksum verification stays genuine — driving the prek version this repo pins. Before the change the step exits 2 with the error chain above; after it, two 500s are absorbed by the 20s/40s backoff and the third attempt installs Go 1.25.0 and runs the hook. An outage that outlasts all four attempts still fails the step, and an interrupted download leaves the partial tarball in prek's scratch directory with nothing under `tools/`, so a retry re-downloads instead of finding a half-installed toolchain. The backoff covers roughly two minutes; the outage behind that run spanned at least 49 seconds. --- ##### Was generative AI tooling used to co-author this PR? - [X] Yes — Claude Code (Opus 5) Generated-by: Claude Code (Opus 5) following [the guidelines](https://github.com/apache/airflow/blob/main/contributing-docs/05_pull_requests.rst#gen-ai-assisted-contributions) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
