sf-update: don't offer a version that was rolled back

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Tamas Csikel
2026-10-24 09:38:41 +02:00
parent 416f1ce862
commit 8aaa702f9f

View File

@@ -341,7 +341,8 @@ impl Store {
.into_iter()
.map(|name| PackageStatus {
installed: self.installed(&name).unwrap_or_default(),
available: old.get(&name).cloned().flatten(),
// A version that failed here isn't offered again.
available: old.get(&name).cloned().flatten().filter(|v| !self.bad(&name).contains(v)),
staged: self.staged(&name),
name,
})