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

Matrix not found during Docker build of unmarked package - Error in loadNamespace() #42

Open
lucytallents opened this issue Sep 23, 2024 · 0 comments
Labels
bug an unexpected problem or unintended behavior

Comments

@lucytallents
Copy link

I'm attempting to build the unmarked package with the webr Docker container as documented in https://r-wasm.github.io/rwasm/articles/rwasm.html, but build() fails because the Matrix package isn't found, despite it being installed

Command (I've also tried without specifying hard dependencies):

build("unmarked", dependencies = NA)

Errors:

Error in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]) : 
  there is no package called 'Matrix'
Calls: loadNamespace ... loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart
Execution halted
make: *** [Makevars:22: tmblib] Error 1
ERROR: compilation failed for package 'unmarked'
* removing '/tmp/RtmpCQg5cK/file13c4db590/unmarked'
Error in wasm_build(pkg, tarball_path, out_dir, compress) : 
  Building wasm binary for package 'unmarked' failed.

Matrix did appear to install successfully, based on this message while build() was running...

packaged installation of 'Matrix' as 'Matrix_1.7-0_R_x86_64-pc-linux-gnu.tar.gz'
* DONE (Matrix)
Appending virtual filesystem metadata for: Matrix_1.7-0.tgz

...and my session info:

R version 4.4.1 (2024-06-14)
Platform: x86_64-pc-linux-gnu
Running under: Ubuntu 24.04 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3 
LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.26.so;  LAPACK version 3.12.0

locale:
[1] C

time zone: UTC
tzcode source: system (glibc)

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] Matrix_1.7-0     unmarked_1.4.3   rwasm_0.2.0.9000

loaded via a namespace (and not attached):
 [1] vctrs_0.6.5      cli_3.6.3        rlang_1.1.4      processx_3.8.4  
 [5] generics_0.1.3   jsonlite_1.8.9   glue_1.7.0       ps_1.8.0        
 [9] pak_0.8.0        fansi_1.0.6      grid_4.4.1       tibble_3.2.1    
[13] filelock_1.0.3   MASS_7.3-60.2    pkgdepends_0.8.0 lifecycle_1.0.4 
[17] compiler_4.4.1   dplyr_1.1.4      pkgcache_2.2.3   fs_1.6.4        
[21] Rcpp_1.0.13      pkgconfig_2.0.3  lattice_0.22-6   R6_2.5.1        
[25] tidyselect_1.2.1 utf8_1.2.4       parallel_4.4.1   pillar_1.9.0    
[29] curl_5.2.3       callr_3.7.6      magrittr_2.0.3   tools_4.4.1     
[33] withr_3.0.1     

My libPaths:

[1] "/root/R/x86_64-pc-linux-gnu-library/4.4"
[2] "/opt/R/4.4.1/lib/R/site-library"        
[3] "/opt/R/4.4.1/lib/R/library"  

Can anyone advise on a way forward, or help me diagnose the underlying issue?

@georgestagg georgestagg added the bug an unexpected problem or unintended behavior label Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug an unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

2 participants