Bioconductor / basilisk.utils

Clone of the Bioconductor repository for the basilisk.utils package.
https://bioconductor.org/packages/devel/bioc/html/basilisk.utils.html
GNU General Public License v3.0
1 stars 5 forks source link

installMiniconda fails on macOS #2

Closed HectorRDB closed 3 years ago

HectorRDB commented 3 years ago

Hi, I am trying to use basilisk for a package. However, I cannot seem to get it to work. I have tried to just run the example function from the package (son.of.basilisk::test()) and it fails... I narrowed it down to the basilisk.utils::installMiniconda() function which fails with

PREFIX=/Users/hector/Library/Caches/basilisk/1.0.2/0
WARNING: md5sum mismatch of tar archive
expected: e947884fafc78860e75e43579fa3c270
     got: 3ed718a7f3f883cbb8d3435c49bfb4d5
Unpacking payload ...
/Users/hector/Library/Caches/BiocFileCache/2c3a4b59646b_Miniconda3-py37_4.8.2-MacOSX-x86_64.sh: line 403: 57486 Done                    { dd if="$THIS_PATH" bs=1 skip=11313903 count=7441 2> /dev/null; dd if="$THIS_PATH" bs=16384 skip=691 count=2528 2> /dev/null; dd if="$THIS_PATH" bs=1 skip=52740096 count=15087 2> /dev/null; }
     57487 Killed: 9               | "$CONDA_EXEC" constructor --extract-tar --prefix "$PREFIX"
/Users/hector/Library/Caches/BiocFileCache/2c3a4b59646b_Miniconda3-py37_4.8.2-MacOSX-x86_64.sh: line 405: 57491 Killed: 9               "$CONDA_EXEC" constructor --prefix "$PREFIX" --extract-conda-pkgs
sh: /Users/hector/Library/Caches/basilisk/1.0.2/0/bin/conda: No such file or directory
Error in basilisk.utils::installMiniconda() : 
  Miniconda installation failed with status code '1'
In addition: Warning messages:
1: In basilisk.utils::installMiniconda() :
  replacing incomplete Miniconda installation at '/Users/hector/Library/Caches/basilisk/1.0.2/0'
2: In system2(conda.bin, c("install", "--yes", "--no-update-deps",  :
  error in running command
sessionInfo()
R version 4.0.3 (2020-10-10)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Catalina 10.15.7

Matrix products: default
BLAS:   /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRblas.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

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

loaded via a namespace (and not attached):
 [1] Rcpp_1.0.5             magrittr_2.0.1         rappdirs_0.3.1        
 [4] tidyselect_1.1.0       bit_4.0.4              lattice_0.20-41       
 [7] R6_2.5.0               rlang_0.4.8            httr_1.4.2            
[10] blob_1.2.1             dplyr_1.0.2            son.of.basilisk_0.99.0
[13] parallel_4.0.3         grid_4.0.3             DBI_1.1.0             
[16] withr_2.3.0            dbplyr_2.0.0           ellipsis_0.3.1        
[19] basilisk_1.0.2         bit64_4.0.5            digest_0.6.27         
[22] assertthat_0.2.1       tibble_3.0.4           lifecycle_0.2.0       
[25] crayon_1.3.4           Matrix_1.2-18          purrr_0.3.4           
[28] vctrs_0.3.5            basilisk.utils_1.0.4   curl_4.3              
[31] memoise_1.1.0          glue_1.4.2             RSQLite_2.2.1         
[34] BiocFileCache_1.12.1   pillar_1.4.7           compiler_4.0.3        
[37] generics_0.1.0         reticulate_1.18        jsonlite_1.7.1        
[40] pkgconfig_2.0.3 

Thanks for the help

HectorRDB commented 3 years ago

Following up, I tried the miniconda package from https://github.com/hafen/rminiconda and it worked fine. Don't know if that helps

LTLA commented 3 years ago

Try using the latest basilisk package (1.2.0).

Each version of basilisk is tied to a specific version of miniconda (otherwise it would just be chaotic to debug). Some older versions of miniconda suffered from a notarization issue with MKL, causing crashes of the R session whenever we attempted to attach the Python library via reticulate. This should be solved with the latest miniconda associated with the latest basilisk.

Edit: Though looking at your error log more closely, it seems that we don't even get to the point of using reticulate. The MD5 checksum mismatch is pretty concerning; perhaps the downloaded miniconda installer is corrupted. I would suggest using the latest package anyway, the 1.0.2 version is frozen so I can't patch it even if it was a problem on my side.

HectorRDB commented 3 years ago

Thanks a lot, updating to 3.12 fixed the issue.