Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[r/ci] R CI fails today with "Error in readRDS(dest) : error reading from connection" #3314

Closed
johnkerl opened this issue Nov 8, 2024 · 5 comments · Fixed by #3319
Closed
Assignees
Labels

Comments

@johnkerl
Copy link
Member

johnkerl commented Nov 8, 2024

R CI has a persistent fail this morning on multiple PRs (I don't believe it to be due to anything we've changed) -- example

https://github.com/single-cell-data/TileDB-SOMA/actions/runs/11744407390/job/32719440280

[1] "methods"   "Rcpp"      "nanotime"  "spdl"      "nanoarrow" "RcppInt64"
Error in readRDS(dest) : error reading from connection
Calls: <Anonymous> ... eval -> eval -> <Anonymous> -> <Anonymous> -> readRDS

[sc-59087]

Docker repro

$ alias dreb
alias dreb='docker run --rm -it --entrypoint=/bin/bash'

$ dreb eddelbuettel/r2u:jammy

# apt-get update
# apt-get install -y git cmake

# cd /tmp
# git clone https://github.com/single-cell-data/TileDB-SOMA
# cd TileDB-SOMA

Then follow lines from our r-ci.yml:

# cd apis/r

# tools/r-ci.sh bootstrap

Then run these in R:

rversion <- paste(strsplit(as.character(getRversion()), split = '\\.')[[1L]][1:2], collapse = '.')
codename <-  system('. /etc/os-release; echo ${VERSION_CODENAME}', intern = TRUE)
repo <- "https://tiledb-inc.r-universe.dev"
(opt <- sprintf('options(repos = c("%s/bin/linux/%s/%s", "%s", getOption("repos")), timeout = 300L)', repo, codename, rversion, repo))
cat(opt, "\n", file = "~/.Rprofile", append = TRUE)

Then

# Rscript tools/install-tiledb-r.R

  comp   vers
1   >= 0.30.0
[1] "methods"   "Rcpp"      "nanotime"  "spdl"      "nanoarrow" "RcppInt64"
Error in readRDS(dest) : error reading from connection
Calls: <Anonymous> ... eval -> eval -> <Anonymous> -> <Anonymous> -> readRDS
Execution halted

In an R session so I can get a traceback:

>
> source('tools/install-tiledb-r.R')
Error in readRDS(dest) : error reading from connection
> traceback()
12: readRDS(dest)
11: utils::available.packages(contriburl = contriburl, method = method,
        ...)
10: (utils::getFromNamespace("install_both", asNamespace("bspm")))(pkgs,
        contriburl, method, dependencies, ...)
9: eval(expr, p)
8: eval(expr, p)
7: eval.parent(exprObj)
6: .doTrace({
       if (missing(pkgs))
           stop("no packages were specified")
       if (type == "both" && !getOption("bspm.version.check", TRUE))
           type <- "binary-source"
       if (is.null(repos)) {
           type <- "source"
       }
       else if (type == "both") {
           pkgs <- (utils::getFromNamespace("install_both", asNamespace("bspm")))(pkgs,
               contriburl, method, dependencies, ...)
           type <- "source"
       }
       else if (type == "binary") {
           if (!length(pkgs <- bspm::install_sys(pkgs)))
               type <- "source"
       }
       else if (type == "binary-source") {
           type <- "both"
           pkgs <- (utils::getFromNamespace("install_fast", asNamespace("bspm")))(pkgs,
               contriburl, method, ...)
           type <- "source"
       }
   })
5: utils::install.packages(intersect(ups, rownames(db))) at install-tiledb-r.R#48
4: eval(ei, envir)
3: eval(ei, envir)
2: withVisible(eval(ei, envir))
1: source("tools/install-tiledb-r.R")
@johnkerl
Copy link
Member Author

johnkerl commented Nov 8, 2024

Running lines from tools/install-tiledb.R interactively:

> utils::install.packages(intersect(ups, rownames(db)))
Error in readRDS(dest) : error reading from connection

> intersect(ups, rownames(db))
[1] "Rcpp"      "nanotime"  "spdl"      "nanoarrow" "RcppInt64"
> utils::install.packages('Rcpp')
Error in readRDS(dest) : error reading from connection
> utils::install.packages('nanotime')
Error in readRDS(dest) : error reading from connection
> utils::install.packages('spdl')
Error in readRDS(dest) : error reading from connection
> utils::install.packages('nanoarrow')
Error in readRDS(dest) : error reading from connection
> utils::install.packages('RcppInt64')
Error in readRDS(dest) : error reading from connection

@johnkerl
Copy link
Member Author

johnkerl commented Nov 8, 2024

When I comment out the .Rprofile line

options(repos = c("https://tiledb-inc.r-universe.dev/bin/linux/jammy/4.4", "https://tiledb-inc.r-universe.dev", getOption("repos")), timeout = 300L)

then the tools/install-tiledb-r.R runs successfully

@johnkerl
Copy link
Member Author

johnkerl commented Nov 8, 2024

@johnkerl
Copy link
Member Author

johnkerl commented Nov 8, 2024

https://github.com/single-cell-data/TileDB-SOMA/actions/runs/11745810131/job/32724737665 just ran to completion.

Problem appears to have been transient.

cc @mojaveazure

@johnkerl johnkerl closed this as completed Nov 8, 2024
@johnkerl johnkerl reopened this Nov 8, 2024
@johnkerl johnkerl assigned mojaveazure and unassigned johnkerl Nov 8, 2024
@johnkerl
Copy link
Member Author

johnkerl commented Nov 8, 2024

@mojaveazure has some follow-up thoughts which he understands well; re-assigning

mojaveazure added a commit that referenced this issue Nov 8, 2024
Remove specific installation steps for tiledb-r as the doublepin was
removed in #3006

resolves #3314

[SC-59087](https://app.shortcut.com/tiledb-inc/story/59087)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants