ci: drop unused Chrome/Microsoft apt sources before apt-get update - #4114
Conversation
GitHub ubuntu runners ship those third-party lists, and a Packages.gz hash mismatch on dl.google.com fails jobs that only install Ubuntu packages. Co-authored-by: Cursor <cursoragent@cursor.com>
|
The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).
|
There was a problem hiding this comment.
Straightforward CI flake mitigation: a guarded helper drops unused Chrome/Microsoft apt sources before every apt-get update in the repo's workflows. Correct and consistent with the existing .github/scripts/ci-*.sh conventions; one non-blocking robustness suggestion about the hardcoded filename list.
Findings: 0 blocking | 1 non-blocking | 1 posted inline
Blockers
- None at the file/PR level.
Non-blocking
- None at the file/PR level.
- 1 suggestion(s)/nit(s) flagged inline on specific lines.
| # runner image layout can never fail the job. | ||
| set -euo pipefail | ||
|
|
||
| sources=( |
There was a problem hiding this comment.
[suggestion] Matching exact filenames makes this fix silently expire: if a future runner image renames the file (e.g. google-chrome-stable.list, or a new microsoft-*.sources variant), every entry misses, the loop no-ops, and the hash-sum-mismatch flake returns with no signal that the mitigation stopped applying. A glob over the same directory would be durable against that layout change while still being narrowly scoped:
for src in /etc/apt/sources.list.d/*google*.list /etc/apt/sources.list.d/*google*.sources \
/etc/apt/sources.list.d/*microsoft*.list /etc/apt/sources.list.d/*microsoft*.sources; do
[ -e "$src" ] || continue
echo "Removing $src"
sudo rm -f "$src"
done(Non-blocking — the current list matches today's ubuntu-latest/ubuntu-24.04-arm images, so the fix works as-is.)
A renamed list on a future runner image would otherwise leave the flake in place with no signal. Co-authored-by: Cursor <cursoragent@cursor.com>
|
@seidroid re-review please |
|
Claude finished @wen-coding's task in 1m 26s —— View job Re-review: APPROVEDThe follow-up commit (
Findings: 0 blocking | 1 non-blocking What changed since the last review
Coverage checkI grepped every
I also confirmed no step in either changed workflow installs anything from a Google or Microsoft repo after the script runs ( Non-blocking[nit] The header's "can never fail the job" claim is now slightly stronger than the code, vs. its sibling script. sudo rm -f "$src" || trueLow practical risk on Verification noteI could not execute |
Match ci-free-disk.sh so a sudo rm miss cannot become a new CI failure under set -e. Co-authored-by: Cursor <cursoragent@cursor.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4114 +/- ##
==========================================
- Coverage 60.94% 59.97% -0.98%
==========================================
Files 2192 2087 -105
Lines 192187 179513 -12674
==========================================
- Hits 117131 107654 -9477
+ Misses 63684 61576 -2108
+ Partials 11372 10283 -1089
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
@seidroid re-review please |
|
Claude finished @wen-coding's task in 1m 16s —— View job Re-review: APPROVED
Findings: 0 blocking | 0 non-blocking What changed since the last reviewOne line, - sudo rm -f "$src"
+ sudo rm -f "$src" || trueThat closes the gap I flagged: the header promises "every removal is guarded so a change to the runner image layout can never fail the job," but It also lands on the same shape as its sibling, Final state of the scriptAll 20 lines read cleanly:
Coverage re-checkEvery
I also re-grepped Minor observation (not a finding)
Verification note
|
Summary
ubuntu-*runners ship Google Chrome (and Microsoft) apt sources.apt-get updatethen fetchesdl.google.comeven when the job only installs Ubuntu packages (build-essential, RocksDB deps).Packages.gzwhose hash does not match the signedReleasefile, failing Cross-Architecture Build and RocksDB Tests (e.g. attempts on (Autobahn) Prove commit-committee identity on giga handshake and learn live dial addresses (CON-358) #4108).apt-get update. We do not install or need Chrome.Test plan
Install system dependenciesno longer hitsdl.google.com/linux/chrome-stable.Install RocksDB dependenciessucceeds without hash-sum mismatch.build-essential(and RocksDB deps) from Ubuntu.Made with Cursor