From 4342fa773a3dce111ff7eff1515db7c37be099c4 Mon Sep 17 00:00:00 2001 From: pat-s Date: Wed, 9 Sep 2026 10:55:15 +0000 Subject: [PATCH] fix(abi): do not error on the nothing-to-repair path (#208) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Why Pipeline 12480 shows this for slots with nothing to do: ``` Error in sprintf("%s/%s: %d objects recorded, none unsafe. Nothing to repair.", : ``` `RPostgres` returns `count(*)` as `integer64`, and `%d` rejects it. So a slot in the **best possible state** — verdicts recorded, nothing unsafe — failed its pipeline step, while slots with real work to do succeeded. Exactly the wrong signal. ## What changed Formats the count as a string. One line, plus a comment recording why `%d` is wrong here. Reviewed-on: https://git.devxy.io/devxy/build-cran-binaries/pulls/208 --- local/list-unsafe-flat-objects.R | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/local/list-unsafe-flat-objects.R b/local/list-unsafe-flat-objects.R index 1937f99..60649a2 100644 --- a/local/list-unsafe-flat-objects.R +++ b/local/list-unsafe-flat-objects.R @@ -141,11 +141,13 @@ if (nrow(rows) == 0L) { call. = FALSE ) } + # `count(*)` arrives as a double (or integer64), and `%d` rejects both, so the + # nothing-to-do path used to die on its own success message. message(sprintf( - "%s/%s: %d objects recorded, none unsafe. Nothing to repair.", + "%s/%s: %s objects recorded, none unsafe. Nothing to repair.", arch, codename, - total + format(as.numeric(total), scientific = FALSE) )) quit(status = 0) }