hildebra / lotus2

Amplicon sequencing pipelines suitable for SSU (16S, 18S), LSU (23S, 28S) and ITS.
http://lotus2.earlham.ac.uk/
GNU General Public License v3.0
52 stars 17 forks source link

fail to install under OSX with conda #29

Closed splaisan closed 1 year ago

splaisan commented 1 year ago

Following info on the related issue 24, I tried the following:

conda create -c conda-forge -c bioconda --strict-channel-priority -n lotus2 
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /opt/miniconda3/envs/lotus2

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate lotus2
#
# To deactivate an active environment, use
#
#     $ conda deactivate

Retrieving notices: ...working... done

I tried installing with conda but it failed

$ conda activate lotus2
$ conda install -c bioconda lotus2
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: | 
Found conflicts! Looking for incompatible packages.
This can take several minutes.  Press CTRL-C to abort.
failed                                                                                                                  

UnsatisfiableError: 

I then tried with mamba

$ mamba install -c conda-forge -c bioconda lotus2

                  __    __    __    __
                 /  \  /  \  /  \  /  \
                /    \/    \/    \/    \
███████████████/  /██/  /██/  /██/  /████████████████████████
              /  / \   / \   / \   / \  \____
             /  /   \_/   \_/   \_/   \    o \__,
            / _/                       \_____/  `
            |/
        ███╗   ███╗ █████╗ ███╗   ███╗██████╗  █████╗
        ████╗ ████║██╔══██╗████╗ ████║██╔══██╗██╔══██╗
        ██╔████╔██║███████║██╔████╔██║██████╔╝███████║
        ██║╚██╔╝██║██╔══██║██║╚██╔╝██║██╔══██╗██╔══██║
        ██║ ╚═╝ ██║██║  ██║██║ ╚═╝ ██║██████╔╝██║  ██║
        ╚═╝     ╚═╝╚═╝  ╚═╝╚═╝     ╚═╝╚═════╝ ╚═╝  ╚═╝

        mamba (1.0.0) supported by @QuantStack

        GitHub:  https://github.com/mamba-org/mamba
        Twitter: https://twitter.com/QuantStack

█████████████████████████████████████████████████████████████

Looking for: ['lotus2']

pkgs/main/osx-64                                              No change
bioconda/noarch                                               No change
bioconda/osx-64                                               No change
pkgs/r/noarch                                                 No change
pkgs/main/noarch                                              No change
pkgs/r/osx-64                                                 No change
conda-forge/noarch                                  10.2MB @   3.8MB/s  3.2s
conda-forge/osx-64                                  25.2MB @   2.3MB/s 12.3s
Encountered problems while solving:
  - nothing provides lambda <2 needed by lotus2-2.01-0

The error is not very verbose, any idea how to fix this?

Thanks in advance

nsoranzo commented 1 year ago

@splaisan Thanks for the detailed report. The issue is due to lambda not being available for macOS in Bioconda, see https://anaconda.org/bioconda/lambda/files and https://github.com/bioconda/bioconda-recipes/blob/master/recipes/lambda/meta.yaml#L13 . Since it seems that's the only package among the direct dependencies of lotus2 that is not available for macOS, I can try to update the lambda bioconda recipe to build that as well.

splaisan commented 1 year ago

thanks @nsoranzo, can I install lambda on my mac using macport to fill the gap? or build it from some source? I use macport (and not brew) but I see a lambda is present there although with a version number 0.1.4 and math related (does not sound right!) https://ports.macports.org/port/lambda/details/

maybe this one is more suited? https://github.com/seqan/lambda/releases/download/lambda-v1.9.5/lambda2-1.9.5-Darwin-x86_64.zip

lambda2 version: 1.9.5 SeqAn version: 2.4.0

thanks S

nsoranzo commented 1 year ago

I think https://github.com/seqan/lambda/releases/tag/lambda-v1.0.3 would be the best, 1.9.5 is actually a 2.x pre-release and AFAIK lotus2 works only with the 1.x series.

Any way, my attempt at building lambda on macOS for bioconda is at https://github.com/bioconda/bioconda-recipes/pull/37996 .

splaisan commented 1 year ago

tried to build from the 1.0.3 source you linked but the build commands found on their wiki do not execute, not enough into cmake to fix it myself, I will wait on your solution. Best S

nsoranzo commented 1 year ago

It took a few more tries, but lambda (1.0.3 and 2.0.0) for macOS is now available in bioconda!

@splaisan Can you try again and let us know?

splaisan commented 1 year ago

Thanks Nicola,

It first failed with conda/mamba install -c bioconda lotus2 with - nothing provides python-igraph needed by swarm-2.1.10-py27_0

but finally worked after adding conda-forge as first repo with mamba install -c conda-forge -c bioconda lotus2

the final recipe on my mac is thus (with mamba installed in base env):

$ conda create -c conda-forge -c bioconda --strict-channel-priority -n lotus2
$ conda activate lotus2
$ mamba install -c conda-forge -c bioconda lotus2

# test
$ lotus2 -v
LotuS 2.22
after quite some time to install many packages, my lotus2 env contains: ``` # packages in environment at /opt/miniconda3/envs/lotus2: # # Name Version Build Channel _r-mutex 1.0.1 anacondar_1 conda-forge argtable2 2.13 h1de35cc_1001 conda-forge arpack 3.7.0 hefb7bc6_2 conda-forge bioconductor-biobase 2.54.0 r41h3be46a4_2 bioconda bioconductor-biocgenerics 0.40.0 r41hdfd78af_0 bioconda bioconductor-biocparallel 1.28.3 r41hb890f52_1 bioconda bioconductor-biomformat 1.22.0 r41hdfd78af_0 bioconda bioconductor-biostrings 2.62.0 r41h3be46a4_2 bioconda bioconductor-dada2 1.22.0 r41hb890f52_2 bioconda bioconductor-delayedarray 0.20.0 r41h3be46a4_2 bioconda bioconductor-genomeinfodb 1.30.1 r41hdfd78af_0 bioconda bioconductor-genomeinfodbdata 1.2.7 r41hdfd78af_2 bioconda bioconductor-genomicalignments 1.30.0 r41h3be46a4_2 bioconda bioconductor-genomicranges 1.46.1 r41h3be46a4_1 bioconda bioconductor-iranges 2.28.0 r41h3be46a4_2 bioconda bioconductor-matrixgenerics 1.6.0 r41hdfd78af_0 bioconda bioconductor-multtest 2.50.0 r41h3be46a4_2 bioconda bioconductor-phyloseq 1.38.0 r41hdfd78af_0 bioconda bioconductor-rhdf5 2.38.1 r41h01c935f_0 bioconda bioconductor-rhdf5filters 1.6.0 r41hb890f52_2 bioconda bioconductor-rhdf5lib 1.16.0 r41h3be46a4_2 bioconda bioconductor-rhtslib 1.26.0 r41h3be46a4_2 bioconda bioconductor-rsamtools 2.10.0 r41hb890f52_2 bioconda bioconductor-s4vectors 0.32.4 r41h3be46a4_0 bioconda bioconductor-shortread 1.52.0 r41hb890f52_2 bioconda bioconductor-summarizedexperiment 1.24.0 r41hdfd78af_0 bioconda bioconductor-xvector 0.34.0 r41h3be46a4_2 bioconda bioconductor-zlibbioc 1.40.0 r41h3be46a4_2 bioconda blast 2.12.0 h0370960_3 bioconda bwidget 1.9.14 h694c41f_1 conda-forge bzip2 1.0.8 h0d85af4_4 conda-forge c-ares 1.18.1 h0d85af4_0 conda-forge ca-certificates 2022.9.24 h033912b_0 conda-forge cairo 1.16.0 h904041c_1014 conda-forge cctools_osx-64 973.0.1 h3eff9a4_10 conda-forge cd-hit 4.8.1 h10c929f_7 bioconda clang 14.0.6 h694c41f_0 conda-forge clang-14 14.0.6 default_h55ffa42_0 conda-forge clang_osx-64 14.0.6 h3113cd8_3 conda-forge clangxx 14.0.6 default_h55ffa42_0 conda-forge clangxx_osx-64 14.0.6 h6f97653_3 conda-forge clustalo 1.2.4 h9722bc1_5 bioconda compiler-rt 14.0.6 h613da45_0 conda-forge compiler-rt_osx-64 14.0.6 hab78ec2_0 conda-forge curl 7.86.0 h57eb407_1 conda-forge entrez-direct 16.2 h193322a_1 bioconda expat 2.5.0 hf0c8a7f_0 conda-forge fasttree 2.1.11 hdcdfbac_1 bioconda font-ttf-dejavu-sans-mono 2.37 hab24e00_0 conda-forge font-ttf-inconsolata 3.000 h77eed37_0 conda-forge font-ttf-source-code-pro 2.038 h77eed37_0 conda-forge font-ttf-ubuntu 0.83 hab24e00_0 conda-forge fontconfig 2.14.1 h5bb23bf_0 conda-forge fonts-conda-ecosystem 1 0 conda-forge fonts-conda-forge 1 0 conda-forge freetype 2.12.1 h3f81eb7_0 conda-forge fribidi 1.0.10 hbcb3906_0 conda-forge gettext 0.21.1 h8a4c099_0 conda-forge gfortran_impl_osx-64 11.3.0 h1f927f5_26 conda-forge gfortran_osx-64 11.3.0 h18f7dce_0 conda-forge glpk 5.0 h3cb5acd_0 conda-forge gmp 6.2.1 h2e338ed_0 conda-forge graphite2 1.3.13 h2e338ed_1001 conda-forge gsl 2.7 h93259b0_0 conda-forge harfbuzz 5.3.0 h08f8713_0 conda-forge hmmer 3.3.2 h9722bc1_2 bioconda icu 70.1 h96cf925_0 conda-forge infernal 1.1.4 pl5321ha5712d3_1 bioconda iqtree 2.2.0.3 h135ad0d_1 bioconda isl 0.25 hb486fe8_0 conda-forge itsx 1.1.3 hdfd78af_1 bioconda jpeg 9e hac89ed1_2 conda-forge k8 0.2.5 h6151dfb_2 bioconda krb5 1.19.3 hb49756b_0 conda-forge lambda 1.0.3 hb77fa79_3 bioconda lca 0.23 h6151dfb_1 bioconda ld64_osx-64 609 h1e06c2b_10 conda-forge lerc 4.0.0 hb486fe8_0 conda-forge libblas 3.9.0 16_osx64_openblas conda-forge libcblas 3.9.0 16_osx64_openblas conda-forge libclang-cpp14 14.0.6 default_h55ffa42_0 conda-forge libcurl 7.86.0 h57eb407_1 conda-forge libcxx 14.0.6 hccf4f1f_0 conda-forge libdeflate 1.14 hb7f2c08_0 conda-forge libedit 3.1.20191231 h0678c8f_2 conda-forge libev 4.33 haf1e3a3_1 conda-forge libffi 3.4.2 h0d85af4_5 conda-forge libgfortran 5.0.0 9_5_0_h97931a8_26 conda-forge libgfortran-devel_osx-64 11.3.0 h824d247_26 conda-forge libgfortran5 11.3.0 h082f757_26 conda-forge libglib 2.74.1 h3ba3332_0 conda-forge libiconv 1.17 hac89ed1_0 conda-forge libidn2 2.3.4 hb7f2c08_0 conda-forge liblapack 3.9.0 16_osx64_openblas conda-forge libllvm13 13.0.1 h64f94b2_2 conda-forge libllvm14 14.0.6 h5b596cc_1 conda-forge libnghttp2 1.47.0 h7cbc4dc_1 conda-forge libopenblas 0.3.21 openmp_h429af6e_3 conda-forge libpng 1.6.38 ha978bb4_0 conda-forge libsqlite 3.39.4 ha978bb4_0 conda-forge libssh2 1.10.0 h7535e13_3 conda-forge libtiff 4.4.0 hdb44e8a_4 conda-forge libunistring 0.9.10 h0d85af4_0 conda-forge libwebp-base 1.2.4 h775f41a_0 conda-forge libxml2 2.10.3 hb9e07b5_0 conda-forge libzlib 1.2.13 hfd90126_4 conda-forge llvm-openmp 15.0.4 h61d9ccf_0 conda-forge llvm-tools 14.0.6 h5b596cc_1 conda-forge lotus2 2.22 hdfd78af_0 bioconda mafft 7.508 ha5712d3_0 bioconda make 4.3 h22f3db7_1 conda-forge metis 5.1.0 h2e338ed_1006 conda-forge minimap2 2.24 h1f540d2_1 bioconda mpc 1.2.1 hbb51d92_0 conda-forge mpfr 4.1.0 h0f52abe_1 conda-forge ncurses 6.3 h96cf925_1 conda-forge openjdk 17.0.3 hbc0c0cd_4 conda-forge openssl 1.1.1s hfd90126_0 conda-forge pango 1.50.11 h7fca291_0 conda-forge pcre 8.45 he49afe7_0 conda-forge pcre2 10.37 h3f55489_1 conda-forge perl 5.32.1 2_h0d85af4_perl5 conda-forge perl-archive-tar 2.40 pl5321hdfd78af_0 bioconda perl-carp 1.50 pl5321hd8ed1ab_0 conda-forge perl-common-sense 3.75 pl5321hd8ed1ab_0 conda-forge perl-compress-raw-bzip2 2.201 pl5321h775f41a_0 conda-forge perl-compress-raw-zlib 2.202 pl5321h775f41a_0 conda-forge perl-encode 3.19 pl5321hb7f2c08_0 conda-forge perl-exporter 5.74 pl5321hd8ed1ab_0 conda-forge perl-exporter-tiny 1.002002 pl5321hd8ed1ab_0 conda-forge perl-extutils-makemaker 7.64 pl5321hd8ed1ab_0 conda-forge perl-getopt-long 2.53 pl5321hdfd78af_0 bioconda perl-io-compress 2.201 pl5321h9722bc1_0 bioconda perl-io-zlib 1.11 pl5321hdfd78af_0 bioconda perl-json 4.10 pl5321hdfd78af_0 bioconda perl-json-xs 2.34 pl5321hcd10b59_5 bioconda perl-list-moreutils 0.430 pl5321hdfd78af_0 bioconda perl-list-moreutils-xs 0.430 pl5321ha5712d3_1 bioconda perl-parent 0.238 pl5321hd8ed1ab_0 conda-forge perl-pathtools 3.75 pl5321h775f41a_0 conda-forge perl-scalar-list-utils 1.63 pl5321h775f41a_0 conda-forge perl-storable 3.15 pl5321h775f41a_0 conda-forge perl-types-serialiser 1.01 pl5321hdfd78af_0 bioconda pip 22.3.1 pyhd8ed1ab_0 conda-forge pixman 0.40.0 hbcb3906_0 conda-forge python 3.11.0 ha621ccb_0_cpython conda-forge python-igraph 0.10.2 py311h19c8b50_1 conda-forge python_abi 3.11 2_cp311 conda-forge r-ade4 1.7_20 r41hce01bf1_0 conda-forge r-ape 5.6_2 r41h4f1a15b_1 conda-forge r-assertthat 0.2.1 r41hc72bb7e_3 conda-forge r-backports 1.4.1 r41h815d134_1 conda-forge r-base 4.1.3 he54549f_3 conda-forge r-bh 1.78.0_0 r41hc72bb7e_1 conda-forge r-bitops 1.0_7 r41h815d134_1 conda-forge r-brio 1.1.3 r41h815d134_1 conda-forge r-callr 3.7.3 r41hc72bb7e_0 conda-forge r-cli 3.4.1 r41h49197e3_1 conda-forge r-cluster 2.1.4 r41h1e4e481_0 conda-forge r-codetools 0.2_18 r41hc72bb7e_1 conda-forge r-colorspace 2.0_3 r41h815d134_1 conda-forge r-crayon 1.5.2 r41hc72bb7e_1 conda-forge r-data.table 1.14.6 r41h557251b_0 conda-forge r-deldir 1.0_6 r41h1e4e481_1 conda-forge r-desc 1.4.2 r41hc72bb7e_1 conda-forge r-diffobj 0.3.5 r41h815d134_1 conda-forge r-digest 0.6.30 r41h49197e3_0 conda-forge r-dplyr 1.0.10 r41h49197e3_1 conda-forge r-ellipsis 0.3.2 r41h815d134_1 conda-forge r-evaluate 0.18 r41hc72bb7e_0 conda-forge r-fansi 1.0.3 r41h815d134_1 conda-forge r-farver 2.1.1 r41h49197e3_1 conda-forge r-foreach 1.5.2 r41hc72bb7e_1 conda-forge r-formatr 1.12 r41hc72bb7e_1 conda-forge r-fs 1.5.2 r41h49197e3_2 conda-forge r-futile.logger 1.4.3 r41hc72bb7e_1004 conda-forge r-futile.options 1.0.1 r41hc72bb7e_1003 conda-forge r-generics 0.1.3 r41hc72bb7e_1 conda-forge r-ggplot2 3.4.0 r41hc72bb7e_0 conda-forge r-glue 1.6.2 r41h815d134_1 conda-forge r-gtable 0.3.1 r41hc72bb7e_1 conda-forge r-hms 1.1.2 r41hc72bb7e_1 conda-forge r-hwriter 1.3.2.1 r41hc72bb7e_1 conda-forge r-igraph 1.3.5 r41h02d1660_0 conda-forge r-interp 1.1_3 r41h49197e3_1 conda-forge r-isoband 0.2.6 r41h49197e3_1 conda-forge r-iterators 1.0.14 r41hc72bb7e_1 conda-forge r-jpeg 0.1_9 r41h815d134_1 conda-forge r-jsonlite 1.8.3 r41h815d134_0 conda-forge r-labeling 0.4.2 r41hc72bb7e_2 conda-forge r-lambda.r 1.2.4 r41hc72bb7e_2 conda-forge r-lattice 0.20_45 r41h815d134_1 conda-forge r-latticeextra 0.6_30 r41hc72bb7e_1 conda-forge r-lifecycle 1.0.3 r41hc72bb7e_1 conda-forge r-magrittr 2.0.3 r41h815d134_1 conda-forge r-mass 7.3_58.1 r41h815d134_1 conda-forge r-matrix 1.5_3 r41hce01bf1_0 conda-forge r-matrixstats 0.62.0 r41h815d134_1 conda-forge r-mgcv 1.8_41 r41h40f944a_0 conda-forge r-munsell 0.5.0 r41hc72bb7e_1005 conda-forge r-nlme 3.1_160 r41h1e4e481_0 conda-forge r-permute 0.9_7 r41hc72bb7e_1 conda-forge r-pillar 1.8.1 r41hc72bb7e_1 conda-forge r-pixmap 0.4_12 r41hc72bb7e_1 conda-forge r-pkgconfig 2.0.3 r41hc72bb7e_2 conda-forge r-pkgload 1.3.2 r41hc72bb7e_0 conda-forge r-plyr 1.8.8 r41h49197e3_0 conda-forge r-png 0.1_7 r41h815d134_1006 conda-forge r-praise 1.0.0 r41hc72bb7e_1006 conda-forge r-prettyunits 1.1.1 r41hc72bb7e_2 conda-forge r-processx 3.8.0 r41h815d134_0 conda-forge r-progress 1.2.2 r41hc72bb7e_3 conda-forge r-ps 1.7.2 r41h815d134_0 conda-forge r-r6 2.5.1 r41hc72bb7e_1 conda-forge r-rcolorbrewer 1.1_3 r41h785f33e_1 conda-forge r-rcpp 1.0.9 r41h49197e3_2 conda-forge r-rcppeigen 0.3.3.9.3 r41h4f1a15b_0 conda-forge r-rcppparallel 5.1.5 r41h49197e3_1 conda-forge r-rcurl 1.98_1.9 r41h815d134_1 conda-forge r-rematch2 2.1.2 r41hc72bb7e_2 conda-forge r-reshape2 1.4.4 r41h49197e3_2 conda-forge r-rlang 1.0.6 r41h49197e3_1 conda-forge r-rprojroot 2.0.3 r41hc72bb7e_1 conda-forge r-scales 1.2.1 r41hc72bb7e_1 conda-forge r-snow 0.4_4 r41hc72bb7e_1 conda-forge r-sp 1.5_1 r41h815d134_0 conda-forge r-stringi 1.7.8 r41h7183e51_1 conda-forge r-stringr 1.4.1 r41hc72bb7e_1 conda-forge r-survival 3.4_0 r41h815d134_1 conda-forge r-testthat 3.1.5 r41h49197e3_1 conda-forge r-tibble 3.1.8 r41h815d134_1 conda-forge r-tidyselect 1.2.0 r41hbe3e9c8_0 conda-forge r-utf8 1.2.2 r41h815d134_1 conda-forge r-vctrs 0.5.1 r41h49197e3_0 conda-forge r-vegan 2.6_4 r41h63324e3_0 conda-forge r-viridislite 0.4.1 r41hc72bb7e_1 conda-forge r-waldo 0.4.0 r41hc72bb7e_1 conda-forge r-withr 2.5.0 r41hc72bb7e_1 conda-forge rdp_classifier 2.13 hdfd78af_1 bioconda readline 8.1.2 h3899abd_0 conda-forge rtk 0.93.2 h6151dfb_2 bioconda sdm 2.05 h66d0458_0 bioconda setuptools 65.5.1 pyhd8ed1ab_0 conda-forge sigtool 0.1.3 h57ddcff_0 conda-forge suitesparse 5.10.1 h7aff33d_1 conda-forge swarm 3.1.2 hb3ea9af_0 bioconda tapi 1100.0.11 h9ce4665_0 conda-forge tbb 2021.7.0 hb8565cd_0 conda-forge texttable 1.6.4 pyhd8ed1ab_0 conda-forge tk 8.6.12 h5dbffcc_0 conda-forge tktable 2.10 h49f0cf7_3 conda-forge tzdata 2022f h191b570_0 conda-forge unzip 6.0 h0d85af4_3 conda-forge vsearch 2.22.1 h984fb42_0 bioconda wget 1.20.3 h52ee1ee_1 conda-forge wheel 0.38.4 pyhd8ed1ab_0 conda-forge xz 5.2.6 h775f41a_0 conda-forge zip 3.0 h0d85af4_1 conda-forge zlib 1.2.13 hfd90126_4 conda-forge zstd 1.5.2 hfa58983_4 conda-forge ```

thanks a lot for the great support! right in time for next week training with Falk ;-)

nsoranzo commented 1 year ago

Great to hear @splaisan , thanks for reporting back!

splaisan commented 1 year ago

oepsy!

I have a new issue when running the second example ./lotus2 -i Example/ -m Example/miSeqMap.sm.txt -o myTestRun2 -s configs/sdm_miSeq2.txt -p miSeq -amplicon_type SSU -forwardPrimer GTGYCAGCMGCCGCGGTAA -reversePrimer GGACTACNVGGGTWTCTAAT -CL dada2 -refDB SLV -taxAligner lambda

I believe this is due to my own R packages mixing up with yours (probably my dada2 &| Rcpp)

$ lotus2 -i $CONDA_PREFIX/share/lotus2-2.22-0/Example/ -m $CONDA_PREFIX/share/lotus2-2.22-0/Example/miSeqMap.sm.txt -o myTestRun2 -s $CONDA_PREFIX/share/lotus2-2.22-0/configs/sdm_miSeq2.txt -p miSeq -amplicon_type SSU -forwardPrimer GTGYCAGCMGCCGCGGTAA -reversePrimer GGACTACNVGGGTWTCTAAT -CL dada2 -refDB SLV -taxAligner lambda
Using Silva SSU ref seq database.
--------------------------------------------------------------------------------
 00:00:00 LotuS 2.22
          ARGS
          perl /opt/miniconda3/envs/lotus2/bin/lotus2 -i /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/Example/
          -m /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/Example/miSeqMap.sm.txt
          -o myTestRun2 -s /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/configs/sdm_miSeq2.txt
          -p miSeq -amplicon_type SSU -forwardPrimer GTGYCAGCMGCCGCGGTAA
          -reversePrimer GGACTACNVGGGTWTCTAAT -CL dada2 -refDB SLV
          -taxAligner lambda
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
 00:00:00 Reading mapping file
          Sequence files are indicated in mapping file.
          Switching to paired end read mode
          Found "SequencingRun" column, with 1 categories (C)
--------------------------------------------------------------------------------
------------ I/O configuration --------------
Input       /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/Example/
Output      myTestRun2
SDM options /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/configs/sdm_miSeq2.txt
TempDir     myTestRun2/tmpFiles/
------------ Configuration LotuS --------------
de novo sequence clustering with DADA2 into ASV's
Sequencing platform     miseq
Amplicon target         bacteria, SSU
Dereplication filter    8:1,4:2,3:3
Clustering algorithm    DADA2 into ASV's
Read mapping (non tax)  minimap2
ASV clustering based on sequence error profiles (-dada2seed 0)
Precluster read merging No
Ref Chimera checking    Yes (DB=/opt/miniconda3/envs/lotus2/share/lotus2-2.22-0//DB//rdp_gold.fa, -chim_skew 2)
deNovo Chimera check    Yes
Tax assignment          Lambda (-LCA_frac 0.8, -LCA_cover 0.5, ids 97,95,93,91,88,78,0, -useBestBlastHitOnly 0)
ReferenceDatabase       SILVA
RefDB location          /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0//DB//SLV_138.1_SSU.fasta
ASV phylogeny           Yes (mafft, fasttree2)
Unclassified ASV's      Kept in matrix
--------------------------------------------
--------------------------------------------------------------------------------
 00:00:01 Demultiplexing, filtering, dereplicating input files, this
          might take some time..
          check progress at myTestRun2/LotuSLogS/LotuS_progout.log
 00:00:01 Finished primary read processing with sdm:
          Reads processed: 500; 500 (pair 1;pair 2)
          Accepted (High qual): 332; 436 (46; 82 end-trimmed)
          Accepted (Mid qual): 10;28
          Rejected: 158; 36
          Dereplication block 0: 13 unique sequences (avg size 9; 117 counts)
          For an extensive report see myTestRun2/LotuSLogS//demulti.log
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
 00:00:01 DADA2 ASV clustering
          check progress at myTestRun2/LotuSLogS/LotuS_progout.log
 CMD failed: /opt/miniconda3/envs/lotus2/bin/Rscript  --vanilla  /opt/miniconda3/envs/lotus2/share/lotus2-2.22-0/bin/R/dada2_pip.R myTestRun2/tmpFiles//demultiplexed/ myTestRun2/tmpFiles/ 0 1 myTestRun2/primary/in.map myTestRun2/tmpFiles//derep.fas 
see myTestRun2/LotuSLogS/LotuS_progout.log for error log

R is OK it seems

$ R
WARNING: ignoring environment value of R_HOME
Error in .makeMessage(..., domain = domain) : 
  3 arguments passed to .Internal(gettext) which requires 2

R version 4.1.3 (2022-03-10) -- "One Push-Up"
Copyright (C) 2022 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin13.4.0 (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

Error in .makeMessage(..., domain = domain, appendLF = appendLF) : 
  3 arguments passed to .Internal(gettext) which requires 2

which R
/opt/miniconda3/envs/lotus2/bin/R

but the $R_LIBS library path is mine (non-canonical) instead of yours (/opt/miniconda3/envs/lotus2/lib/R/library)

.libPaths()
[1] "/opt/R_LIBS"
the log file contains ``` $ cat myTestRun2/LotuSLogS/LotuS_progout.log This is sdm (simple demultiplexer) 2.05 beta. Checking for reverse primers on 1st read. Checking for switched pairs. Run with 1 cores.At PID-0292-1_S1_L001_R1_001.fastq.sm.gz: Writing demultiplexed files to : myTestRun2/tmpFiles//demultiplexed/ 67.2% of 250 reads accepted (89.6% end-trimmed) Pair 2: 92% of 250 reads accepted (83.2% end - trimmed) At PID-0292-2_S2_L001_R1_001.fastq.sm.gz: Writing demultiplexed files to : myTestRun2/tmpFiles//demultiplexed/ 69.6% of 250 reads accepted (92% end-trimmed) Pair 2: 93.6% of 250 reads accepted (84% end - trimmed) Evaluating and writing dereplicated reads.. Dereplication: 13 unique sequences (avg size 9; 117 counts) 193/206 not passing derep conditions (223 counts; 8:1,4:2,3:3) sdm 2.05 beta Input File: several Output File: myTestRun2/tmpFiles//demulti.1.fna Reads processed: 500; 500 (pair 1;pair 2) Rejected: 158; 36 Accepted (High qual): 332; 436 (46; 82 end-trimmed) Accepted (Mid qual): 10;28 Singletons among these: 0; 0 Bad Reads recovered with dereplication: 8 Short amplicon mode. Min/Avg/Max stats Pair 1 - sequence Length : 101/169.756/170 - Quality : 27/35.244/38 - Median sequence Length : 0, Quality : 0 - Accum. Error 0.120159 Trimmed due to: > 25 avg qual_ in 20 bp windows : 0; 0 > (3.75) acc. errors, trimmed seqs : 0; 0 Rejected due to: < min Sequence length (100) : 34; 36 -after Quality trimming : 34; 36 < avg Quality (27) : 0; 0 < window (50 nt) avg. Quality (25) : 23; 27 > max Sequence length (1000) : 0; 0 > (8) homo-nt run : 0; 0 > (0) amb. Bases : 0; 0 > (2.5) binomial est. errors : 124; 0 Specific sequence searches: -With fwd Primer remaining (<= 0 mismatches, required) : 0; 0 -With rev Primer remaining (<= 0 mismatches) : 0; 0 -Barcode unidentified (max 0 errors) : 0 SampleID Barcode Instances ANG1 166 ANG2 174 Time taken: : 84ms WARNING: ignoring environment value of R_HOME Error: Bioconductor version '3.16' requires R version '4.2'; use `BiocManager::install(version = '3.14')` with R version 4.1; see https://bioconductor.org/install In addition: Warning messages: 1: package ‘dada2’ was built under R version 4.2.1 2: package ‘Rcpp’ was built under R version 4.2.0 Execution halted ```
splaisan commented 1 year ago

I tried:

cat myTestRun2/LotuSLogS/LotuS_progout.log

This is sdm (simple demultiplexer) 2.05 beta.

Checking for reverse primers on 1st read.
Checking for switched pairs.
Run with 1 cores.At PID-0292-1_S1_L001_R1_001.fastq.sm.gz: 
Writing demultiplexed files to : myTestRun2/tmpFiles//demultiplexed/
67.2% of 250 reads accepted (89.6% end-trimmed)
Pair 2: 92% of 250 reads accepted (83.2% end - trimmed)
At PID-0292-2_S2_L001_R1_001.fastq.sm.gz: 
Writing demultiplexed files to : myTestRun2/tmpFiles//demultiplexed/
69.6% of 250 reads accepted (92% end-trimmed)
Pair 2: 93.6% of 250 reads accepted (84% end - trimmed)
Evaluating and writing dereplicated reads..

Dereplication: 13 unique sequences (avg size 9; 117 counts)
193/206 not passing derep conditions (223 counts; 8:1,4:2,3:3)

sdm 2.05 beta
Input File:  several
Output File: myTestRun2/tmpFiles//demulti.1.fna

Reads processed: 500; 500 (pair 1;pair 2)
Rejected: 158; 36
Accepted (High qual): 332; 436 (46; 82 end-trimmed)
Accepted (Mid qual): 10;28
Singletons among these: 0; 0
Bad Reads recovered with dereplication: 8
Short amplicon mode.
Min/Avg/Max stats Pair 1
     - sequence Length : 101/169.756/170
     - Quality :   27/35.244/38
     - Median sequence Length : 0, Quality : 0
     - Accum. Error 0.120159
Trimmed due to:
  > 25 avg qual_ in 20 bp windows :         0; 0
  > (3.75) acc. errors, trimmed seqs :     0; 0
Rejected due to:
  < min Sequence length (100)  :                34; 36
       -after Quality trimming :           34; 36
  < avg Quality (27)  :                    0; 0
  < window (50 nt) avg. Quality (25)  :    23; 27
  > max Sequence length (1000)  :               0; 0
  > (8) homo-nt run  :                     0; 0
  > (0) amb. Bases  :                      0; 0
  > (2.5) binomial est. errors :           124; 0
Specific sequence searches:
  -With fwd Primer remaining (<= 0 mismatches, required) : 0; 0
  -With rev Primer remaining (<= 0 mismatches) :           0; 0
  -Barcode unidentified (max 0 errors) :                   0

SampleID    Barcode Instances
ANG1        166
ANG2        174
Time taken: : 76ms
WARNING: ignoring environment value of R_HOME
Bioconductor version 3.14 (BiocManager 1.30.19), R 4.1.3 (2022-03-10)
Warning message:
package(s) not installed when version(s) same as or greater than current; use
  `force = TRUE` to re-install: 'dada2' 
Detected 2 samples in batch C (1/1) .. Computing error profiles
Learning error profiles for the forward reads:
Error in learnErrors(filtFs, nbases = bp4error, multithread = ncores) : 
  could not find function "learnErrors"
Error in errF : object 'errF' not found
Execution halted

the R_LIBS is somehow better but not yet fixed

$R
...

> .libPaths()
[1] "/opt/miniconda3/envs/lotus2/lib/R/library"
[2] "/opt/R_LIBS"

> version
               _                           
platform       x86_64-apple-darwin13.4.0   
arch           x86_64                      
os             darwin13.4.0                
system         x86_64, darwin13.4.0        
status                                     
major          4                           
minor          1.3                         
year           2022                        
month          03                          
day            10                          
svn rev        81868                       
language       R                           
version.string R version 4.1.3 (2022-03-10)
nickname       One Push-Up
splaisan commented 1 year ago

update

I renamed my $HOME .Renviron to avoid any definition of R_LIBS and tried the example on both my mac and my ubuntu server (same R install and conda env install method and paths)

under ubuntu it leads to a working R and the example2 commands runs (currently building the LAMBDA index) on mac it keeps failing but I do not have anymore the R systematic error Error in .makeMessage(..., domain = domain) : 3 arguments passed to .Internal(gettext) which requires 2

Bioconductor version 3.14 (BiocManager 1.30.19), R 4.1.3 (2022-03-10)
Warning message:
package(s) not installed when version(s) same as or greater than current; use
  `force = TRUE` to re-install: 'dada2' 
Detected 2 samples in batch C (1/1) .. Computing error profiles
Learning error profiles for the forward reads:
Error in learnErrors(filtFs, nbases = bp4error, multithread = ncores) : 
  could not find function "learnErrors"
Error in errF : object 'errF' not found
Execution halted

By comparing my packages between mac and ubuntu, I found that the mac instance is missing one R package to load dada2 (GenomeInfoDbData)

> library("dada2")
Loading required package: Rcpp
Error: package or namespace load failed for ‘dada2’ in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]):
 there is no package called ‘GenomeInfoDbData’

> BiocManager::install("GenomeInfoDbData")
Bioconductor version 3.14 (BiocManager 1.30.19), R 4.1.3 (2022-03-10)
Installing package(s) 'GenomeInfoDbData'
trying URL 'https://bioconductor.org/packages/3.14/data/annotation/src/contrib/GenomeInfoDbData_1.2.7.tar.gz'
Content type 'application/octet-stream' length 11193674 bytes (10.7 MB)
==================================================
downloaded 10.7 MB

* installing *source* package ‘GenomeInfoDbData’ ...
** using staged installation
** data
** inst
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (GenomeInfoDbData)

The downloaded source packages are in
    ‘/private/var/folders/9t/3znyqdv97hd88564_qzqt39d78gyqt/T/RtmpETXFDY/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done

> library("dada2")
# OK

after adding manually ‘GenomeInfoDbData’ in R, the run is now also building the LAMBDA index

nsoranzo commented 1 year ago

Not sure where are R 4.2 / Bioconductor 3.16 packages coming from, but they are not from the conda environment. I can only guess there was some environment variable interfering. Any way nothing we can fix on lotus2 / bioconda side, I believe, sorry.

splaisan commented 1 year ago

I finally fixed it.

My system R was indeed interfering.

I had defined R_LIBS in my $HOME .Renviron and this was propagated in conda. I need this for RStudio and R on my laptop so I could not really remove it but I found a way by editing the the lotus activate and deactivate scripts in your conda to swap, not only RSTUDIO_WHICH_R, but also R_HOME and R_LIBS.

Maybe this issue comes back for other users, I had it already for other condas and had to quit on it, now I have a fix

code * activate ``` $ cat $CONDA_PREFIX/envs/lotus2/etc/conda/activate.d/activate-r-base.sh #!/usr/bin/env sh R CMD javareconf > /dev/null 2>&1 || true # store existing RSTUDIO_WHICH_R if [[ ! -z ${RSTUDIO_WHICH_R+x} ]]; then export RSTUDIO_WHICH_R_PREV="$RSTUDIO_WHICH_R" fi export RSTUDIO_WHICH_R="$CONDA_PREFIX/bin/R" # store existing R_HOME if [[ ! -z ${R_HOME+x} ]]; then export R_HOME_PREV="$R_HOME" fi export R_HOME="$CONDA_PREFIX/lib/R" # store existing R_LIBS if [[ ! -z ${R_LIBS+x} ]]; then export R_LIBS_PREV="$R_LIBS" fi export R_LIBS="$CONDA_PREFIX/lib/R/library" export R_LIBS_USER="${R_LIBS}" export R_LIBS_SITE="${R_LIBS}" ``` * deactivate ``` $ cat $CONDA_PREFIX/envs/lotus2/etc/conda/deactivate.d/deactivate-r-base.sh #!/usr/bin/env sh # restore pre-existing RSTUDIO_WHICH_R if [[ ! -z ${RSTUDIO_WHICH_R_PREV+x} ]]; then export RSTUDIO_WHICH_R="$RSTUDIO_WHICH_R_PREV" unset RSTUDIO_WHICH_R_PREV else unset RSTUDIO_WHICH_R fi # restore pre-existing R_HOME if [[ ! -z ${R_HOME_PREV+x} ]]; then export R_HOME="$R_HOME_PREV" unset R_HOME_PREV else unset R_HOME fi # restore pre-existing R_LIBS if [[ ! -z ${R_LIBS_PREV+x} ]]; then export R_LIBS="$R_LIBS_PREV" export R_LIBS_USER="${R_LIBS}" export R_LIBS_SITE="${R_LIBS}" unset R_LIBS_PREV else unset R_LIBS fi ```

Now the ticket is officially closed, I could run the demo without any error message