fix(local): route multi-signature packages to human triage in the proposer
A package whose failing builds match more than one auto-proposable signature (e.g. some logs hit `tbb-stddef-removed` and others `rcppparallel-bundled-tbb`) produced two candidate registry entries with the same package/platforms/versions key, so the candidate set failed `validate-patches.R` with "ambiguous duplicate entries" and the whole proposer run aborted. Add a pure `dedupe_candidates()` that keeps a package only when it maps to a single signature and routes genuinely ambiguous packages (conflicting fix tiers) to human triage instead of guessing between them. The proposer prints the skipped packages and proceeds with the unambiguous candidates.
This commit is contained in:
parent
77508f8fc5
commit
ec64fb6db8
1 changed files with 80 additions and 1 deletions
|
|
@ -135,9 +135,25 @@ for (r in report) {
|
|||
}
|
||||
}
|
||||
|
||||
# A package that maps to more than one auto-proposable signature is ambiguous
|
||||
# (conflicting fix tiers) and would collide on the same registry key; route it
|
||||
# to human triage instead of emitting both.
|
||||
split_candidates <- dedupe_candidates(candidates)
|
||||
candidates <- split_candidates$keep
|
||||
if (length(split_candidates$ambiguous) > 0L) {
|
||||
cat("\nAmbiguous (multiple signatures) -> human triage, not proposed:\n")
|
||||
for (pkg in names(split_candidates$ambiguous)) {
|
||||
cat(sprintf(
|
||||
" %s: %s\n",
|
||||
pkg,
|
||||
toString(split_candidates$ambiguous[[pkg]])
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
if (length(candidates) == 0L) {
|
||||
cat(
|
||||
"No auto-proposable candidates (nothing classified, safe, and unregistered).\n"
|
||||
"\nNo auto-proposable candidates (nothing classified, safe, unregistered, and unambiguous).\n"
|
||||
)
|
||||
q(status = 0)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue