@actions/artifact: a non-200 blob response is not destroyed before the retry, so the process waits for the 3-min socket timeout
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- 1-3 Stunden
- Anfängerfreundlichkeit
- 78/100
- Issue-Typ
- Bug
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- github, node.js, typescript
Rechercherichtung
Beginne bei streamExtractExternal im Paket @actions/artifact, wo laut Issue eine Nicht-200-Antwort vor dem Retry offengelassen wird. Lies die Antwortverarbeitung und ihre Tests und reproduziere dann den Fall 404-then-200 mit dem im Issue beschriebenen lokalen Mock. Fertig ist die Arbeit, wenn der Retry erfolgreich ist und der Prozess umgehend beendet wird, statt auf das Socket-Timeout zu warten.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Package: @actions/artifact, as bundled in actions/download-artifact@v8.
What happens.
- The first GET of the blob URL gets a non-200 answer (seen with 404 and 503).
streamExtractExternalthrows without consuming or destroying the response.- The download retries after 5 s, the retry succeeds, and the step logs success.
- The first response's socket stays open.
@actions/http-client's default request timeout (req.setTimeout(3 * 60000)) then keeps node alive until it fires, so the step ends about 180 s after the blob request instead of at once.
Reproducer. We used a local mock of the artifact API whose blob URL answers 404 (or 503) once, then 200. We ran download-artifact@v8's dist/index.js with GITHUB_API_URL pointed at the mock:
- With the one error, it logs
Failed to download artifact after 1 retries due to Unexpected HTTP response from blob storage: 404 Not Found, then success, and exits at 180.3 s. - With a clean 200, it exits in 0.2 s.
No proxy is involved.
In real runs (self-hosted Linux runners, 181 download steps over 40 workflow runs): the step ran past 60 s 5 times. Each time it ended 181.4 s after its "Redirecting to blob download url" line, and the download itself took about 7.7 s (one failed GET, the 5 s wait, a 1.6 s retry).
Suggested fix. In streamExtractExternal, destroy response.message (or read it to the end) before throwing on a non-200 status, so the failed attempt's socket is released.
Workaround on our side: a 1-min step timeout on the download, then a second try.
- Vorherrschende Sprache
- TypeScript
- Sterne
- 5.9k
- Forks
- 1.8k
- Ø Merge
- 15 Min.
- Gemergte PRs (30 T.)
- 1
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Keine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus actions/toolkit
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag
-
@actions/io: `mv(file, dest)` replaces `dest` when it is a symlink to a directory instead of moving into itEvtl. vergeben @bardrop hat das vor 7 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
Maintainer antworten meist innerhalb von 1 Tag
-
@actions/exec: `exec(commandLine)` drops `""` arguments and trims trailing spaces of the last argumentEvtl. vergeben @bardrop hat das vor 7 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
actions/toolkit#2565 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
@actions/cache: downloadCacheHttpClientConcurrent never stops its progress timer on failure, so the step hangs until the job times outEvtl. vergeben @YodHeVauHe hat das vor 46 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 82/100
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in actions/toolkit
Ähnliche Issues
-
type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 2 Tagen
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 67/100
db-ux-design-system/core-web#8856 ·
Maintainer antworten meist innerhalb von 1 Tag
-
'!' breaking change is lost when the commit also has an empty BREAKING CHANGE footerEvtl. vergeben @wittdennis hat das heute übernommen. Offenpriority: p3 type: bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
googleapis/release-please#2971 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 87/100
Maintainer antworten meist innerhalb von 1 Tag
-
🛠️ dette technique
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 61/100
betagouv/mon-entreprise#4752 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 5 Tagen