dev-desktop: make the get-all-crates refresh robust against index squashes and OOM #1307
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.36) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.36 · 191 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.315
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #1307"
general
weight: 0.35
Mark-Simulacrum
Two fixes to
refresh-crates.sh, the script behind the (still disabled)get-all-cratesjob on dev desktops.Survive crates.io-index squashes
The crates.io-index repository is periodically squashed and force-pushed upstream.
git pull --forcethen fails with "refusing to merge unrelated histories", breaking the job until someone removesthe clone by hand.
The script now fetches and hard-resets to
origin/HEAD(plusgit clean -fdx) instead of pulling. It also:set -xto reduce journal noiseGIT_TERMINAL_PROMPT=0)get-all-cratesby absolute pathLimit download concurrency (
-j 4)The job was getting OOM-killed.
get-all-crateskeeps each downloaded crate in memory until it is written, and does not bound the number of pending writes (for_each_concurrent(None, …)). With thedefault of 50 concurrent requests, downloads outpace disk writes, and memory grows until
MemoryMaxis hit.Testing on a dev desktop showed only slight memory growth at
-j 5, so this uses-j 4for some headroom. The proper fix is bounding pending writes inget-all-cratesitself; this is a stopgap until then:Not in this PR
The timer stays disabled. Before enabling it, I plan to do a supervised full run and to check disk space for
/var/cache/all-crateson the desktops.alternatives