From ecf324541d1e995860957ecf66a4eac765b3dd3f Mon Sep 17 00:00:00 2001 From: Harald Sitter Date: Sat, 16 Aug 2025 16:36:01 +0200 Subject: [PATCH] vacuum: sort artifacts so they have consistent order (and notably so erofs comes before erofs.caibx, preventing the latter to match the match rule for the former) --- upload-vacuum/main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/upload-vacuum/main.go b/upload-vacuum/main.go index 70caa7e..4fb617f 100644 --- a/upload-vacuum/main.go +++ b/upload-vacuum/main.go @@ -93,7 +93,9 @@ type release struct { func readSHA256s(toKeep []string, releases map[string]release) []string { sha256s := []string{} for _, key := range toKeep { - for _, artifact := range releases[key].artifacts { + artifacts := releases[key].artifacts + sort.Strings(artifacts) // Sort artifacts to ensure consistent order + for _, artifact := range artifacts { sha256 := readSHA256(artifact + ".sha256") if sha256 == "" { log.Println("Failed to read SHA256 for", artifact)