Skip to content

fix(deps): drop ggpubr for cowplot; unbreaks R-CMD-check on oldrel-2 - #36

Merged
eliotmcintire merged 1 commit into
developmentfrom
fix/drop-ggpubr-for-cowplot
Sep 1, 2026
Merged

eliotmcintire merged 1 commit into
developmentfrom
fix/drop-ggpubr-for-cowplot

Conversation

@eliotmcintire

Copy link
Copy Markdown
Contributor

Unblocks #34, #35 and every other PR: the ubuntu-latest (oldrel-2) leg has failed on every branch since late July, and it is not caused by any of them.

The failure is not what it looks like

The visible error is a vignette failure, but that is downstream:

derive_simplif.cpp:376:28: error: ‘R_ClosureFormals’ was not declared in this scope
ERROR: compilation failed for package ‘Deriv’
...
Error in loadVignetteBuilder(pkgdir, TRUE) :

Deriv 4.3.0 was published 2026-07-23 — a month after this repo's last green run (development, 2026-06-21). It uses R_ClosureFormals, an R >= 4.5 C-API entry point, while declaring only Depends: Rcpp with no minimum R version. So it builds on the R 4.5.x legs and fails to compile on oldrel-2's R 4.4.3. The dependency install aborts, the vignette builder is never installed, and rcmdcheck then dies in loadVignetteBuilder().

That explains the whole pattern: devel / release / oldrel-1 (all R 4.5.x) pass, oldrel-2 (R 4.4.3) fails, and it presents as a vignette error on a package whose vignette was not the problem.

Why we were pulling in Deriv at all

fireSenseUtils → ggpubr → car → pbkrtest → doBy → Deriv

ggpubr was used in exactly one line of the package:

# R/DEoptim_fns.R:267
invisible(ggpubr::ggarrange(plotlist = ff))

ff is a plain list of ggplots. cowplot::plot_grid() takes the same plotlist argument, and cowplot was already a Suggests — already used by plot_summaries.R (:323, :329) behind a requireNamespace() guard.

The change

  • R/DEoptim_fns.R: ggpubr::ggarrange(plotlist = ff) → cowplot::plot_grid(plotlist = ff)
  • DESCRIPTION: drop ggpubr from Imports; move cowplot Suggests → Imports

Removes 14 packages from the dependency tree: ggpubr, car, carData, pbkrtest, doBy, Deriv, lme4, quantreg, SparseM, MatrixModels, nloptr, minqa, abind, Formula.

No NAMESPACE or roxygen change — both packages were used via ::, neither had an @importFrom.

Notes

  • The one behavioural difference to check on review: plot_grid()'s default spacing/alignment is not identical to ggarrange()'s. visualizeDE() arranges parameter histograms, so this is cosmetic, but it is a real difference rather than a pure no-op.
  • The requireNamespace("cowplot") guard at plot_summaries.R:185 is now redundant (cowplot is an Import). Left in place — harmless, and out of scope here.
  • Not addressed: Deriv's missing R (>= 4.5) constraint is an upstream CRAN bug and worth reporting to its maintainer, since it will bite anything else on R 4.4.

R-CMD-check has failed on the ubuntu oldrel-2 leg (R 4.4.3) since late July,
on every branch. The visible error was a vignette failure, but that is a
downstream symptom:

    derive_simplif.cpp:376:28: error: 'R_ClosureFormals' was not declared
    ERROR: compilation failed for package 'Deriv'
    ...
    Error in loadVignetteBuilder(pkgdir, TRUE)

Deriv 4.3.0 (published 2026-07-23, a month after this repo's last green run
on 2026-06-21) uses R_ClosureFormals, an R >= 4.5 C-API entry point, while
declaring only `Depends: Rcpp` with no minimum R version. So it builds on the
R 4.5.x legs and fails to compile on R 4.4.x. The dependency install aborts,
the vignette builder is never installed, and rcmdcheck then dies in
loadVignetteBuilder() -- which is why this reads as a vignette problem.

Deriv reaches this package only through a single plotting call:

    fireSenseUtils -> ggpubr -> car -> pbkrtest -> doBy -> Deriv

and ggpubr was used in exactly one line, arranging a plain list of ggplots.
cowplot::plot_grid() takes the same `plotlist` argument, and cowplot was
already a Suggests, already used by plot_summaries.R behind a
requireNamespace() guard.

- R/DEoptim_fns.R: ggpubr::ggarrange(plotlist = ff) -> cowplot::plot_grid()
- DESCRIPTION: drop ggpubr from Imports; move cowplot Suggests -> Imports

Removes 14 packages from the dependency tree: ggpubr, car, carData, pbkrtest,
doBy, Deriv, lme4, quantreg, SparseM, MatrixModels, nloptr, minqa, abind,
Formula.

No NAMESPACE or roxygen change: both packages were used via `::`, neither had
an @importFrom.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01T3NTQTNStSLZ3mA3CsLcon
@eliotmcintire
eliotmcintire merged commit e3f3b2c into development Sep 1, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant