Incompatible methods ("Ops.S7_object", "+.gg") for "+"

Hello everyone,

After having had to revert versions of a set of packages recently, ggplot2 is not working anymore. However, I am unable to identify the dependencies that really cause the issue. Any suggestion or hint would be more than appreciated. Many thanks in advance.

library(tidyverse)
ggplot(data = mtcars, aes(x = wt, y = mpg)) + geom_point()

Warning: Incompatible methods ("Ops.S7_object", "+.gg") for "+"Error in ggplot(data = mtcars, aes(x = wt, y = mpg)) + geom_point() :
non-numeric argument to binary operator

sessioninfo::session_info()
#> ─ Session info ───────────────
#>  setting  value
#>  version  R version 4.2.2 (2022-10-31)
#>  os       Red Hat Enterprise Linux 8.10 (Ootpa)
#>  system   x86_64, linux-gnu
#>  ui       X11
#>  language (EN)
#>  collate  en_US.UTF-8
#>  ctype    en_US.UTF-8
#>  tz       Europe/Copenhagen
#>  date     2025-09-18
#>  pandoc   2.19.2 @ /usr/lib/rstudio-server/bin/quarto/bin/tools/ (via rmarkdown)
#>  quarto   1.2.269 @ /usr/lib/rstudio-server/bin/quarto/bin/quarto
#> 
#> ─ Packages ───────────────────────────────────────────────────────────────────
#>  package     * version date (UTC) lib source
#>  cli           3.6.2   2023-12-11 [1] CRAN (R 4.2.2)
#>  digest        0.6.35  2024-03-11 [1] CRAN (R 4.3.2)
#>  evaluate      1.0.5   2025-08-27 [1] CRAN (R 4.2.2)
#>  fastmap       1.1.1   2023-02-24 [3] CRAN (R 4.2.2)
#>  fs            1.6.3   2023-07-20 [3] CRAN (R 4.2.2)
#>  glue          1.7.0   2024-01-09 [1] CRAN (R 4.2.2)
#>  htmltools     0.5.8.1 2024-04-04 [1] CRAN (R 4.2.2)
#>  knitr         1.46    2024-04-06 [1] CRAN (R 4.2.2)
#>  lifecycle     1.0.4   2023-11-07 [1] CRAN (R 4.2.2)
#>  reprex        2.1.1   2024-07-06 [1] CRAN (R 4.2.2)
#>  rlang         1.1.3   2024-01-10 [1] CRAN (R 4.2.2)
#>  rmarkdown     2.29    2024-11-04 [1] CRAN (R 4.2.2)
#>  rstudioapi    0.17.1  2024-10-22 [1] CRAN (R 4.2.2)
#>  sessioninfo   1.2.3   2025-02-05 [1] CRAN (R 4.2.2)
#>  withr         3.0.2   2024-10-28 [1] CRAN (R 4.2.2)
#>  xfun          0.43    2024-03-25 [1] CRAN (R 4.2.2)
#>  yaml          2.3.8   2023-12-11 [1] CRAN (R 4.2.2)
#> 
#>  [1] .../bin/Rpackages
#>  [2] .../software/R/4.2.2/lib64/R/library
#>  [3] .../software/R-packages/4.2.2

Welcome! Your session_info() seems to be from a different session where ggplot2 and many of its dependencies were not loaded. It would help if you could edit your post and include a reprex from:

reprex::reprex({
  library(tidyverse)
  ggplot(data = mtcars, aes(x = wt, y = mpg)) + geom_point()
  sessioninfo::session_info()
})

Thanks a ton for the reply @margusl . Indeed, when I tried to run reprex in exactly the way, you outlined, I get yet another error:


This reprex appears to crash R.
See standard output and standard error for more details.

Standard output and error


Quitting from lines  at lines 20-23 [unnamed-chunk-2] (cushy-kitty_reprex.spin.Rmd)
Error in xfun::upload_imgur(file, key, ..., include_xml = TRUE) : 
  Failed to upload cushy-kitty_reprex_files/figure-gfm/unnamed-chunk-2-1.png (reason: 1025)

However, here is the output from sessioninfo::session_info(). Many thanks for any advice!

─ Session info ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 setting  value
 version  R version 4.2.2 (2022-10-31)
 os       Red Hat Enterprise Linux 8.10 (Ootpa)
 system   x86_64, linux-gnu
 ui       RStudio
 language (EN)
 collate  en_US.UTF-8
 ctype    en_US.UTF-8
 tz       Europe/Copenhagen
 date     2025-09-18
 rstudio  2022.12.0+353 Elsbeth Geranium (server)
 pandoc   2.19.2 @ /usr/lib/rstudio-server/bin/quarto/bin/tools/ (via rmarkdown)
 quarto   1.2.269 @ /usr/lib/rstudio-server/bin/quarto/bin/quarto

─ Packages ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 !  package              * version     date (UTC) lib source
    abind                  1.4-8       2024-09-12 [1] CRAN (R 4.2.2)
    AnnotationDbi          1.60.2      2023-03-10 [3] Bioconductor
    AnnotationFilter       1.22.0      2022-11-01 [3] Bioconductor
    ape                    5.7-1       2023-03-13 [3] CRAN (R 4.2.2)
    aplot                  0.2.9       2025-09-12 [1] CRAN (R 4.2.2)
    assertthat             0.2.1       2019-03-21 [1] CRAN (R 4.2.2)
    backports              1.5.0       2024-05-23 [1] CRAN (R 4.2.2)
    base64enc              0.1-3       2015-07-28 [1] CRAN (R 4.2.2)
    beeswarm               0.4.0       2021-06-01 [1] CRAN (R 4.2.2)
    Biobase                2.58.0      2022-11-01 [3] Bioconductor
    BiocFileCache          2.6.1       2023-02-17 [3] Bioconductor
    BiocGenerics         * 0.48.1      2023-11-01 [1] Bioconductor
    BiocIO                 1.8.0       2022-11-01 [3] Bioconductor
    BiocManager            1.30.26     2025-06-05 [1] CRAN (R 4.2.2)
    BiocParallel           1.32.6      2023-03-17 [3] Bioconductor
    biomaRt                2.54.1      2023-03-20 [3] Bioconductor
    Biostrings             2.66.0      2022-11-01 [3] Bioconductor
    biovizBase             1.46.0      2022-11-01 [3] Bioconductor
    bit                    4.6.0       2025-03-06 [1] CRAN (R 4.2.2)
    bit64                  4.6.0-1     2025-01-16 [1] CRAN (R 4.2.2)
    bitops                 1.0-9       2024-10-03 [1] CRAN (R 4.2.2)
    blob                   1.2.4       2023-03-17 [3] CRAN (R 4.2.2)
    BSgenome               1.66.3      2023-02-16 [3] Bioconductor
    bslib                  0.5.0       2023-06-09 [3] CRAN (R 4.2.2)
    cachem                 1.0.8       2023-05-01 [3] CRAN (R 4.2.2)
    CAGEfightR             1.18.0      2022-11-01 [3] Bioconductor
    callr                  3.7.6       2024-03-25 [1] CRAN (R 4.2.2)
    checkmate              2.3.3       2025-08-18 [1] CRAN (R 4.2.2)
 VP cli                    3.6.1       2023-12-11 [3] CRAN (R 4.2.2) (on disk 3.6.2)
    cluster                2.1.8.1     2025-03-12 [1] CRAN (R 4.2.2)
    clusterProfiler        4.6.2       2023-03-05 [3] Bioconductor
    codetools              0.2-20      2024-03-31 [1] CRAN (R 4.2.2)
    colorspace             2.1-1       2024-07-26 [1] CRAN (R 4.2.2)
    cowplot                1.2.0       2025-07-07 [1] CRAN (R 4.2.2)
    crayon                 1.5.3       2024-06-20 [1] CRAN (R 4.2.2)
    curl                   7.0.0       2025-08-19 [1] CRAN (R 4.2.2)
 VP data.table             1.14.8      2025-07-10 [3] CRAN (R 4.2.2) (on disk 1.17.8)
 VP DBI                    1.1.3       2024-06-02 [3] CRAN (R 4.2.2) (on disk 1.2.3)
 VP dbplyr                 2.3.3       2025-09-10 [3] CRAN (R 4.2.2) (on disk 2.5.1)
    DelayedArray           0.24.0      2022-11-01 [3] Bioconductor
    deldir                 2.0-4       2024-02-28 [1] CRAN (R 4.2.2)
    dendsort               0.3.4       2021-04-20 [1] CRAN (R 4.2.2)
    dichromat              2.0-0.1     2022-05-02 [3] CRAN (R 4.2.2)
 VP digest                 0.6.33      2024-03-11 [3] CRAN (R 4.3.2) (on disk 0.6.35)
    DOSE                   3.24.2      2022-11-21 [3] Bioconductor
    downloader             0.4.1       2025-03-26 [1] CRAN (R 4.2.2)
    dplyr                * 1.1.2       2023-04-20 [3] CRAN (R 4.2.2)
    ellipsis               0.3.2       2021-04-29 [1] CRAN (R 4.2.2)
    enrichplot             1.18.4      2023-04-03 [3] Bioconductor
    ensembldb              2.22.0      2022-11-01 [3] Bioconductor
 VP evaluate               0.21        2025-08-27 [3] CRAN (R 4.2.2) (on disk 1.0.5)
    factoextra             1.0.7       2020-04-01 [1] CRAN (R 4.2.2)
 VP fansi                  1.0.4       2023-12-08 [3] CRAN (R 4.2.2) (on disk 1.0.6)
    farver                 2.1.1       2022-07-06 [3] CRAN (R 4.2.2)
    fastmap                1.1.1       2023-02-24 [3] CRAN (R 4.2.2)
    fastmatch              1.1-6       2024-12-23 [1] CRAN (R 4.2.2)
    fgsea                  1.24.0      2022-11-01 [3] Bioconductor
    filelock               1.0.3       2023-12-11 [1] CRAN (R 4.2.2)
    fitdistrplus           1.2-4       2025-07-03 [1] CRAN (R 4.2.2)
    forcats              * 1.0.0       2023-01-29 [3] CRAN (R 4.2.2)
    foreach                1.5.2       2022-02-02 [1] CRAN (R 4.2.2)
    foreign                0.8-90      2025-03-31 [1] CRAN (R 4.2.2)
    Formula                1.2-5       2023-02-24 [3] CRAN (R 4.2.2)
    fs                     1.6.3       2023-07-20 [3] CRAN (R 4.2.2)
    future                 1.67.0      2025-07-29 [1] CRAN (R 4.2.2)
    future.apply           1.20.0      2025-06-06 [1] CRAN (R 4.2.2)
 VP generics               0.1.3       2025-05-09 [3] CRAN (R 4.2.2) (on disk 0.1.4)
    GenomeInfoDb         * 1.34.9      2023-02-02 [3] Bioconductor
    GenomeInfoDbData       1.2.11      2024-04-11 [1] Bioconductor
    GenomicAlignments      1.34.1      2023-03-09 [3] Bioconductor
    GenomicFeatures        1.50.4      2023-01-24 [3] Bioconductor
    GenomicRanges        * 1.50.2      2022-12-16 [3] Bioconductor
    GGally                 2.2.1       2024-02-14 [1] CRAN (R 4.2.2)
    ggbeeswarm             0.7.2       2023-04-29 [1] CRAN (R 4.2.2)
    ggbio                  1.46.0      2022-11-01 [1] Bioconductor
    ggdendro               0.2.0       2024-02-23 [1] CRAN (R 4.2.2)
    ggforce                0.4.1       2022-10-04 [3] CRAN (R 4.2.2)
    ggfun                  0.2.0       2025-07-15 [1] CRAN (R 4.2.2)
    ggplot2              * 4.0.0       2025-09-11 [1] CRAN (R 4.2.2)
    ggplotify              0.1.2       2023-08-09 [1] CRAN (R 4.2.2)
    ggraph                 2.1.0       2022-10-09 [3] CRAN (R 4.2.2)
    ggrastr                1.0.2       2023-06-01 [1] CRAN (R 4.2.2)
    ggrepel                0.9.3       2023-02-03 [3] CRAN (R 4.2.2)
    ggridges               0.5.7       2025-08-27 [1] CRAN (R 4.2.2)
    ggstats                0.11.0      2025-09-15 [1] CRAN (R 4.2.2)
    ggtree                 3.6.2       2022-11-10 [3] Bioconductor
    globals                0.18.0      2025-05-08 [1] CRAN (R 4.2.2)
 VP glue                   1.6.2       2024-01-09 [3] CRAN (R 4.2.2) (on disk 1.7.0)
    GO.db                  3.16.0      2023-04-18 [3] Bioconductor
    goftest                1.2-3       2021-10-07 [3] CRAN (R 4.2.2)
    GOSemSim               2.24.0      2022-11-01 [3] Bioconductor
    graph                  1.80.0      2023-10-24 [1] Bioconductor
    graphlayouts           1.0.0       2023-05-01 [3] CRAN (R 4.2.2)
    gridExtra              2.3         2017-09-09 [3] CRAN (R 4.2.2)
    gridGraphics           0.5-1       2020-12-13 [3] CRAN (R 4.2.2)
    gson                   0.1.0       2023-03-07 [3] CRAN (R 4.2.2)
    gtable                 0.3.6       2024-10-25 [1] CRAN (R 4.2.2)
    Gviz                   1.42.1      2023-02-17 [3] Bioconductor
    HDO.db                 0.99.1      2023-04-18 [3] Bioconductor
    here                   1.0.2       2025-09-15 [1] CRAN (R 4.2.2)
    Hmisc                  5.2-3       2025-03-16 [1] CRAN (R 4.2.2)
    hms                    1.1.3       2023-03-21 [3] CRAN (R 4.2.2)
    htmlTable              2.4.3       2024-07-21 [1] CRAN (R 4.2.2)
 VP htmltools              0.5.5       2024-04-04 [3] CRAN (R 4.2.2) (on disk 0.5.8.1)
 VP htmlwidgets            1.6.2       2023-12-06 [3] CRAN (R 4.2.2) (on disk 1.6.4)
    httpuv                 1.6.11      2023-05-11 [3] CRAN (R 4.2.2)
    httr                   1.4.7       2023-08-15 [1] CRAN (R 4.2.2)
    ica                    1.0-3       2022-07-08 [3] CRAN (R 4.2.2)
    igraph                 1.5.0.1     2023-07-23 [3] CRAN (R 4.2.2)
    interp                 1.1-4       2023-03-31 [3] CRAN (R 4.2.2)
    IRanges              * 2.32.0      2022-11-01 [3] Bioconductor
    irlba                  2.3.5.1     2022-10-03 [3] CRAN (R 4.2.2)
    iterators              1.0.14      2022-02-05 [3] CRAN (R 4.2.2)
    jpeg                   0.1-11      2025-03-21 [1] CRAN (R 4.2.2)
    jquerylib              0.1.4       2021-04-26 [3] CRAN (R 4.2.2)
    jsonlite               2.0.0       2025-03-27 [1] CRAN (R 4.2.2)
    KEGGREST               1.38.0      2022-11-01 [3] Bioconductor
    KernSmooth             2.23-26     2025-01-01 [1] CRAN (R 4.2.2)
 VP knitr                  1.43        2024-04-06 [3] CRAN (R 4.2.2) (on disk 1.46)
    later                  1.3.1       2023-05-02 [3] CRAN (R 4.2.2)
    lattice                0.22-7      2025-04-02 [1] CRAN (R 4.2.2)
    latticeExtra           0.6-31      2025-09-10 [1] CRAN (R 4.2.2)
    lazyeval               0.2.2       2019-03-15 [3] CRAN (R 4.2.2)
    leiden                 0.4.3.1     2023-11-17 [1] CRAN (R 4.2.2)
 VP lifecycle              1.0.3       2023-11-07 [3] CRAN (R 4.2.2) (on disk 1.0.4)
    listenv                0.9.1       2024-01-29 [1] CRAN (R 4.2.2)
    lmtest                 0.9-40      2022-03-21 [3] CRAN (R 4.2.2)
    lubridate            * 1.9.2       2023-02-10 [3] CRAN (R 4.2.2)
 VP magrittr               2.0.3       2025-09-12 [3] CRAN (R 4.2.2) (on disk 2.0.4)
    MASS                   7.3-60.0.1  2024-01-13 [1] CRAN (R 4.3.2)
    Matrix                 1.5-1       2022-09-13 [2] CRAN (R 4.2.2)
    MatrixGenerics         1.10.0      2022-11-01 [3] Bioconductor
    matrixStats            1.3.0       2024-04-11 [1] CRAN (R 4.2.2)
    memoise                2.0.1       2021-11-26 [3] CRAN (R 4.2.2)
    mgcv                   1.9-3       2025-04-04 [1] CRAN (R 4.2.2)
    mime                   0.13        2025-03-17 [1] CRAN (R 4.2.2)
    miniUI                 0.1.2       2025-04-17 [1] CRAN (R 4.2.2)
    nlme                   3.1-168     2025-03-31 [1] CRAN (R 4.2.2)
    nnet                   7.3-20      2025-01-01 [1] CRAN (R 4.2.2)
    OrganismDbi            1.40.0      2022-11-01 [1] Bioconductor
    parallelly             1.45.1      2025-07-24 [1] CRAN (R 4.2.2)
    patchwork              1.3.2       2025-08-25 [1] CRAN (R 4.2.2)
    pbapply                1.7-4       2025-07-20 [1] CRAN (R 4.2.2)
    permute                0.9-8       2025-06-25 [1] CRAN (R 4.2.2)
 VP pillar                 1.9.0       2025-09-17 [3] CRAN (R 4.2.2) (on disk 1.11.1)
    pkgconfig              2.0.3       2019-09-22 [3] CRAN (R 4.2.2)
    plotly                 4.11.0      2025-06-19 [1] CRAN (R 4.2.2)
    plyr                   1.8.8       2022-11-11 [3] CRAN (R 4.2.2)
    png                    0.1-8       2022-11-29 [3] CRAN (R 4.2.2)
    polyclip               1.10-6      2023-09-27 [1] CRAN (R 4.3.2)
    prettyunits            1.2.0       2023-09-24 [1] CRAN (R 4.2.2)
    processx               3.8.6       2025-02-21 [1] CRAN (R 4.2.2)
    progress               1.2.3       2023-12-06 [1] CRAN (R 4.2.2)
    progressr              0.15.1      2024-11-22 [1] CRAN (R 4.2.2)
    promises               1.2.0.1     2021-02-11 [3] CRAN (R 4.2.2)
    ProtGenerics           1.34.0      2023-10-24 [1] Bioconductor
    ps                     1.9.1       2025-04-12 [1] CRAN (R 4.2.2)
    purrr                * 1.1.0       2025-07-10 [1] CRAN (R 4.2.2)
    qvalue                 2.30.0      2022-11-01 [3] Bioconductor
 VP R6                     2.5.1       2025-02-15 [3] CRAN (R 4.2.2) (on disk 2.6.1)
    RANN                   2.6.1       2019-01-08 [3] CRAN (R 4.2.2)
    rappdirs               0.3.3       2021-01-31 [1] CRAN (R 4.2.2)
    RBGL                   1.79.0      2024-04-11 [1] Github (Bioconductor/RBGL@ebeedfa)
    RColorBrewer           1.1-3       2022-04-03 [3] CRAN (R 4.2.2)
    Rcpp                   1.0.12      2024-01-09 [1] CRAN (R 4.3.2)
    RcppAnnoy              0.0.21      2023-07-02 [3] CRAN (R 4.2.2)
    RCurl                  1.98-1.14   2024-01-09 [1] CRAN (R 4.2.2)
    readr                * 2.1.4       2023-02-10 [3] CRAN (R 4.2.2)
    reprex                 2.1.1       2024-07-06 [1] CRAN (R 4.2.2)
    reshape2               1.4.4       2020-04-09 [3] CRAN (R 4.2.2)
    restfulr               0.0.16      2025-06-27 [1] CRAN (R 4.2.2)
    reticulate             1.30        2023-06-09 [3] CRAN (R 4.2.2)
    rjson                  0.2.21      2022-01-09 [3] CRAN (R 4.2.2)
 VP rlang                  1.1.1       2024-01-10 [3] CRAN (R 4.2.2) (on disk 1.1.3)
 VP rmarkdown              2.23        2024-11-04 [3] CRAN (R 4.2.2) (on disk 2.29)
    ROCR                   1.0-11      2020-05-02 [3] CRAN (R 4.2.2)
    rpart                  4.1.24      2025-01-07 [1] CRAN (R 4.2.2)
    rprojroot              2.1.1       2025-08-26 [1] CRAN (R 4.2.2)
    Rsamtools              2.14.0      2022-11-01 [3] Bioconductor
    RSQLite                2.3.1       2023-04-03 [3] CRAN (R 4.2.2)
 VP rstudioapi             0.15.0      2024-10-22 [3] CRAN (R 4.2.2) (on disk 0.17.1)
    rtracklayer            1.58.0      2022-11-01 [3] Bioconductor
    Rtsne                  0.16        2022-04-17 [3] CRAN (R 4.2.2)
    S4Vectors            * 0.36.2      2023-02-26 [3] Bioconductor
    S7                   * 0.2.0       2024-11-07 [1] CRAN (R 4.2.2)
    sass                   0.4.7       2023-07-15 [3] CRAN (R 4.2.2)
    scales                 1.4.0       2025-04-24 [1] CRAN (R 4.2.2)
    scattermore            1.2         2023-06-12 [3] CRAN (R 4.2.2)
    scatterpie             0.2.6       2025-09-12 [1] CRAN (R 4.2.2)
    sctransform            0.3.5       2022-09-21 [3] CRAN (R 4.2.2)
    sessioninfo            1.2.3       2025-02-05 [1] CRAN (R 4.2.2)
    SeuratObject           4.1.3       2022-11-07 [3] CRAN (R 4.2.2)
    shadowtext             0.1.2       2022-04-22 [3] CRAN (R 4.2.2)
    shiny                * 1.7.4.1     2023-07-06 [3] CRAN (R 4.2.2)
    sp                     2.2-0       2025-02-01 [1] CRAN (R 4.2.2)
    spatstat.data          3.1-8       2025-08-18 [1] CRAN (R 4.2.2)
    spatstat.geom          3.5-0       2025-07-20 [1] CRAN (R 4.2.2)
    spatstat.random        3.1-5       2023-05-11 [3] CRAN (R 4.2.2)
    spatstat.sparse        3.1-0       2024-06-21 [1] CRAN (R 4.2.2)
    spatstat.univar        3.1-4       2025-07-13 [1] CRAN (R 4.2.2)
    spatstat.utils         3.1-5       2025-07-17 [1] CRAN (R 4.2.2)
    stringi                1.7.12      2023-01-11 [3] CRAN (R 4.2.2)
    stringr              * 1.5.2       2025-09-08 [1] CRAN (R 4.2.2)
    SummarizedExperiment   1.28.0      2022-11-01 [3] Bioconductor
    survival               3.8-3       2024-12-17 [1] CRAN (R 4.2.2)
    tensor                 1.5.1       2025-06-17 [1] CRAN (R 4.2.2)
 VP tibble               * 3.2.1       2025-06-08 [3] CRAN (R 4.2.2) (on disk 3.3.0)
    tidygraph              1.2.3       2023-02-01 [3] CRAN (R 4.2.2)
    tidyr                * 1.3.0       2023-01-24 [3] CRAN (R 4.2.2)
 VP tidyselect             1.2.0       2024-03-11 [3] CRAN (R 4.2.2) (on disk 1.2.1)
    tidytree               0.4.6       2023-12-12 [1] CRAN (R 4.2.2)
    tidyverse            * 2.0.0       2023-02-22 [1] CRAN (R 4.2.2)
    timechange             0.2.0       2023-01-11 [3] CRAN (R 4.2.2)
    treeio                 1.22.0      2022-11-01 [3] Bioconductor
    tsne                   0.1-3.1     2022-03-28 [1] CRAN (R 4.2.2)
    tweenr                 2.0.2       2022-09-06 [3] CRAN (R 4.2.2)
    tzdb                   0.4.0       2023-05-12 [3] CRAN (R 4.2.2)
 VP utf8                   1.2.3       2025-06-08 [3] CRAN (R 4.2.2) (on disk 1.2.6)
    VariantAnnotation      1.44.1      2023-02-15 [3] Bioconductor
 VP vctrs                  0.6.3       2023-12-01 [3] CRAN (R 4.2.2) (on disk 0.6.5)
    vegan                  2.7-1       2025-06-05 [1] CRAN (R 4.2.2)
    vipor                  0.4.7       2023-12-18 [1] CRAN (R 4.2.2)
    viridis                0.6.5       2024-01-29 [1] CRAN (R 4.2.2)
    viridisLite            0.4.2       2023-05-02 [3] CRAN (R 4.2.2)
    withr                  3.0.2       2024-10-28 [1] CRAN (R 4.2.2)
 VP xfun                   0.39        2024-03-25 [3] CRAN (R 4.2.2) (on disk 0.43)
    XML                    3.99-0.16.1 2024-01-22 [1] CRAN (R 4.2.2)
    xml2                   1.3.5       2023-07-06 [3] CRAN (R 4.2.2)
    xtable                 1.8-4       2019-04-21 [3] CRAN (R 4.2.2)
    XVector                0.38.0      2022-11-01 [3] Bioconductor
    yaml                   2.3.8       2023-12-11 [1] CRAN (R 4.2.2)
    yulab.utils            0.2.1       2025-08-19 [1] CRAN (R 4.2.2)
    zlibbioc               1.44.0      2022-11-01 [3] Bioconductor
    zoo                    1.8-14      2025-04-10 [1] CRAN (R 4.2.2)

 [1] /maps/projects/ralab/people/pbr316/bin/Rpackages
 [2] /maps/direct/software/R/4.2.2/lib64/R/library
 [3] /maps/projects/scarball/apps/Modules/software/R-packages/4.2.2

 * ── Packages attached to the search path.
 V ── Loaded and on-disk version mismatch.
 P ── Loaded and on-disk path mismatch.

─────────────────────────────────────────────────────────────

I'm afraid that this session_info()is also from different session -- that simple tidyverse + ggplot() snippet in your first post can't load all those Bioconductor, gg* , spatial, etc packages. Though the fact that reprex() had something to upload to Imgur hints that ggplot might actually work in a clean R session. Have you tried restarting R?

If you do need to fiddle with package versions, I'd start with ggplot2, reverting it to pre-4.0 version (e.g to 3.5.2) should clear S7 dependencies

But you do have quite a mix there. For example that xfun from 2024 includes Imgur API key that's not valid anymore and it's the reason of reprex error. Updating xfun to at least 0.51 should fix this.

Once again, many thanks for the quick reply and help @margusl as reverting ggplot back to v3.5.2 did the trick. Good incentive to get familiar with S7 objects.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.