Skip to content

ci: Install Git in the Tier 2 Linux build recovers dpkg before each retry - #5506

Merged
vpacher merged 2 commits into
masterfrom
fix/5504-install-git-dpkg
Nov 23, 2026
Merged

vpacher merged 2 commits into
masterfrom
fix/5504-install-git-dpkg

Conversation

@vpacher

@vpacher vpacher commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Problem

The Install Git 📦 step of Build 🧱 / Rust Tier 2 Linux 🐧 (build) cannot recover when its timeout 180 stops apt-get install while dpkg unpacks (#5504). Its retry loop runs apt-get update and apt-get install again, but not dpkg --configure -a, so every retry fails at once with E: dpkg was interrupted. This failed #5142 (fork PR, no prebaked image) in run 45113911635, attempt 3, while archive.ubuntu.com sent about 100 to 200 KB/s.

Change

Before each attempt, the loop runs dpkg --configure -a || true and, after the index refresh, apt-get -f install -y. This is what Install Tier 2 Packages 📦 in the same job already does (job 134123589625). The .deb files that an earlier attempt downloaded stay in apt's cache, so the next attempt does not download them again. The prebaked branch of the step does not change.

Tests

Check RED (e8ec3d3) GREEN
test_tier2_apt_cache.test_install_git_recovers_dpkg_before_each_retry: runs the step's real retry loop with mocked apt-get and dpkg. An install stopped in the unpack leaves dpkg interrupted, and apt refuses until dpkg --configure -a. Cases: 0, 1, 2 and 3 stopped installs. fails: with 1 stopped install all 3 attempts fail; no attempt starts with the recovery passes: 0 to 2 stopped installs pass, 3 fail as before; each attempt starts with dpkg --configure -a, then apt-get update, then apt-get -f install
The other ci/test_*.py that read build-project.yaml (82 modules) pass on Linux (7 of them fail only on macOS, as on master)

Real run of the new step in a fresh ubuntu:26.04 container (the job's image) on 2026-11-23: the mirror was still slow, attempt 1 failed, the recovery ran, and attempt 2 installed git (rc=0, 221 s, dpkg --audit clean).

No user-visible change, so no features ledger line. No new workflow file. Tiers 1 to 4 do not apply (CI only).

Test cost: no Rust tests. The new case runs in about 0.5 s and starts 4 short shell processes.

Refs #5504 (PR 1 of 2; PR 2 bounds the runtime delta apt in ci-runtime.py)

🤖 Generated with Claude Code

vpacher and others added 2 commits November 23, 2026 10:50
Run the Install Git retry loop of the Tier 2 Linux build with mocked
apt-get and dpkg. An install that a timeout stops in the unpack leaves
dpkg interrupted, and every later apt install refuses to run until
dpkg --configure -a. Today one such stop fails all 3 attempts (run
45113911635).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Before each attempt the Install Git retry loop of the Tier 2 Linux
build runs dpkg --configure -a and apt-get -f install, as the Tier 2
package step does. A timeout that stops the install in the unpack no
longer fails the retries; the downloaded .debs stay in apt's cache.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant