From 0255cfd1e522b667292e9b928184f3161bb55602 Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Fri, 29 May 2026 08:45:35 +0200 Subject: [PATCH 1/2] Fix observation table column width for columns with NA This fixes an error "! Can't coerce from `-Inf` to an integer." in case of columns with NAs. --- assets/differentialabundance_report.qmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/differentialabundance_report.qmd b/assets/differentialabundance_report.qmd index 5ea48940..0ed74f61 100644 --- a/assets/differentialabundance_report.qmd +++ b/assets/differentialabundance_report.qmd @@ -1365,7 +1365,7 @@ if (all(minimal_fetchngs_cols %in% colnames(observations))) { # Coerce per column rather than via apply (which flattens the frame to a # character matrix and silently drops any column containing an NA, because # max(nchar(NA)) is NA and `NA <= 20` is filtered out by `which`). - col_widths <- map_int(observations, \(x) max(nchar(as.character(x)), na.rm = TRUE)) + col_widths <- map_int(observations, \(x) max(nchar(as.character(x)), 0L, na.rm = TRUE)) additional_useful_cols <- names(col_widths)[col_widths <= 20] } From 64c6fb7a4ed9b3f6d36e0ff96698e41a67696fde Mon Sep 17 00:00:00 2001 From: Gregor Sturm Date: Fri, 29 May 2026 08:50:45 +0200 Subject: [PATCH 2/2] update changelog --- CHANGELOG.md | 1 + assets/differentialabundance_report.qmd | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1968dd72..2cdebcf6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -44,6 +44,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed +- [[#739](https://github.com/nf-core/differentialabundance/pull/739)] - Fix issue in quarto report data overview table in cases of columns with NAs ([@grst](https://github.com/grst), review by [@pinin4fjords](https://github.com/pinin4fjords))) - [[#738](https://github.com/nf-core/differentialabundance/pull/738)] - Fix conda failing tests before release ([@atrigila](https://github.com/atrigila), review by [@mashehu](https://github.com/mashehu)). - [[#729](https://github.com/nf-core/differentialabundance/pull/729)] - Skip nf-schema path-existence validation for `igenomes_base` so launches succeed when the default `s3://ngi-igenomes/igenomes/` bucket is not reachable from the user's environment ([@pinin4fjords](https://github.com/pinin4fjords), review by [@atrigila](https://github.com/atrigila)). - [[#725](https://github.com/nf-core/differentialabundance/issues/725)] - Tighten `report_file` schema pattern to explicitly model the comma-separated multi-report form and validate each segment's extension ([@pinin4fjords](https://github.com/pinin4fjords), review by [@atrigila](https://github.com/atrigila)). diff --git a/assets/differentialabundance_report.qmd b/assets/differentialabundance_report.qmd index 0ed74f61..5f94a21a 100644 --- a/assets/differentialabundance_report.qmd +++ b/assets/differentialabundance_report.qmd @@ -1365,7 +1365,7 @@ if (all(minimal_fetchngs_cols %in% colnames(observations))) { # Coerce per column rather than via apply (which flattens the frame to a # character matrix and silently drops any column containing an NA, because # max(nchar(NA)) is NA and `NA <= 20` is filtered out by `which`). - col_widths <- map_int(observations, \(x) max(nchar(as.character(x)), 0L, na.rm = TRUE)) + col_widths <- map_int(observations, \(x) max(nchar(as.character(x)), 0L, na.rm = TRUE)) additional_useful_cols <- names(col_widths)[col_widths <= 20] }