AlexsLemonade / refinebio

Refine.bio harmonizes petabytes of publicly available biological data into ready-to-use datasets for cancer researchers and AI/ML scientists.
https://www.refine.bio/
Other
128 stars 19 forks source link

Fix "is.na() applied to non-(list or vector) of type 'NULL'" for salmon image build #3220

Closed arkid15r closed 1 year ago

arkid15r commented 1 year ago

Context

In order to restore staging/prod deploy process CI/CD tests need to be fixed.

Problem or idea

Upon renv init execution renv::init(bioconductor = "3.6") the following error started to appear:

> renv::init(bioconductor = "3.6")
* Using Bioconductor version '3.6'.
Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
trying URL 'https://bioconductor.org/packages/3.6/bioc/src/contrib/BiocInstaller_1.28.0.tar.gz'
Content type 'application/octet-stream' length 18624 bytes (18 KB)
==================================================
downloaded 18 KB

* installing *source* package ‘BiocInstaller’ ...
** R
** inst
** preparing package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded
Bioconductor version 3.6 (BiocInstaller 1.28.0), ?biocLite for help
A new version of Bioconductor is available after installing the most recent
  version of R; see http://bioconductor.org/install
* DONE (BiocInstaller)

The downloaded source packages are in
    ‘/tmp/Rtmpm8bl6T/downloaded_packages’
Bioconductor version 3.6 (BiocInstaller 1.28.0), ?biocLite for help
A new version of Bioconductor is available after installing the most recent
  version of R; see http://bioconductor.org/install
Error in is.na(x) :
  (converted from warning) is.na() applied to non-(list or vector) of type 'NULL'
Traceback (most recent calls last):
23: renv::init(bioconductor = "3.6")
22: renv_dependencies_scope(project, action = "init")
21: withCallingHandlers(dependencies(path, progress = FALSE, errors = errors,
        dev = TRUE), renv.dependencies.error = renv_dependencies_error_handler(message,
        errors))
20: dependencies(path, progress = FALSE, errors = errors, dev = TRUE)
19: renv_dependencies_impl(path = path, root = root, progress = progress,
        errors = errors, dev = dev, ...)
18: renv_dependencies_find(path, root)
17: lapply(path, renv_dependencies_find_impl, root = root, depth = 0)
16: FUN(X[[i]], ...)
15: renv_dependencies_find_dir(path, root, depth)
14: map(children, renv_dependencies_find_impl, root = root, depth = depth)
13: lapply(x, f, ...)
12: FUN(X[[i]], ...)
11: renv_dependencies_find_dir(path, root, depth)
10: renv_renvignore_exec(path, root, path)
 9: renv_renvignore_pattern(path, root)
 8: renv_renvignore_parse(contents, parent)
 7: sort(unique(unlist(map(include, function(rule) {
        idx <- gregexpr("(?:/|$)", rule, perl = TRUE)[[1L]]
        gsub("^/*", "/", substring(rule, 1L, idx))
    }))))
 6: sort.default(unique(unlist(map(include, function(rule) {
        idx <- gregexpr("(?:/|$)", rule, perl = TRUE)[[1L]]
        gsub("^/*", "/", substring(rule, 1L, idx))
    }))))
 5: sort.int(x, na.last = na.last, decreasing = decreasing, ...)
 4: .signalSimpleWarning("is.na() applied to non-(list or vector) of type 'NULL'",
        quote(is.na(x)))
 3: withRestarts({
        .Internal(.signalCondition(simpleWarning(msg, call), msg,
            call))
        .Internal(.dfltWarn(msg, call))
    }, muffleWarning = function() NULL)
 2: withOneRestart(expr, restarts[[1L]])
 1: doWithOneRestart(return(expr), restart)

Solution or next step

Troubleshoot and fix the R exception.

arkid15r commented 1 year ago

Fixed in https://github.com/AlexsLemonade/refinebio/pull/3230