DADA2 in R (return code -11)

Dear all,
I am getting the following error
Plugin error from dada2:

An error was encountered while running DADA2 in R (return code -11), please inspect stdout and stderr to learn more.

I am using the following code

qiime dada2 denoise-paired
--i-demultiplexed-seqs paired-end-demux-trimmed.qza
--p-trunc-len-f 0
--p-trunc-len-r 0
--p-trim-left-f 200
--p-trim-left-r 200
--o-representative-sequences rep-seqs-dada2.qza
--o-table table-dada2.qza
--o-denoising-stats stats-dada2.qza

I also attach my input artifact for visualisation

Any advice on how to set the parameters to get a successful processing?

.demux.qzv (307.0 KB)

Hi @rotifer - please rerun the command with the --verbose flag and provide the complete output here - without that we cannot begin to understand the nature of the error. Thanks!

(qiime2-2020.2) Ulis-MacBook-Pro:Tovel16S uli$ qiime dada2 denoise-paired \

–i-demultiplexed-seqs paired-end-demux-trimmed.qza
–p-trunc-len-f 0
–p-trunc-len-r 0
–p-trim-left-f 220
–p-trim-left-r 200
–o-representative-sequences rep-seqs-dada2.qza
–o-table table-dada2.qza
–o-denoising-stats stats-dada2.qza
–verbose
Running external command line application(s). This may print messages to stdout and/or stderr.
The command(s) being run are below. These commands cannot be manually re-run as they will depend on temporary files that no longer exist.

Command: run_dada_paired.R /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/forward /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/reverse /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/output.tsv.biom /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/track.tsv /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/filt_f /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/filt_r 0 0 220 200 2.0 2.0 2 consensus 1.0 1 1000000

R version 3.6.1 (2019-07-05)
Loading required package: Rcpp

*** caught segfault ***
address 0x18, cause ‘memory not mapped’

Traceback:
1: dyn.load(file, DLLpath = DLLpath, …)
2: library.dynam(lib, package, package.lib)
3: loadNamespace(package, lib.loc)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ attr(package, “LibPath”) <- which.lib.loc ns <- loadNamespace(package, lib.loc) env <- attachNamespace(ns, pos = pos, deps, exclude, include.only)}, error = function(e) { P <- if (!is.null(cc <- conditionCall(e))) paste(" in", deparse(cc)[1L]) else “” msg <- gettextf(“package or namespace load failed for %s%s:\n %s”, sQuote(package), P, conditionMessage(e)) if (logical.return) message(paste(“Error:”, msg), domain = NA) else stop(msg, call. = FALSE, domain = NA)})
8: library(pkg, character.only = TRUE, logical.return = TRUE, lib.loc = lib.loc, quietly = quietly)
9: .getRequiredPackages2(pkgInfo, quietly = quietly)
10: library(dada2)
11: withCallingHandlers(expr, warning = function(w) invokeRestart(“muffleWarning”))
12: suppressWarnings(library(dada2))
An irrecoverable exception occurred. R is aborting now …
Traceback (most recent call last):
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 257, in denoise_paired
run_commands([cmd])
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 36, in run_commands
subprocess.run(cmd, check=True)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/subprocess.py”, line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command ‘[‘run_dada_paired.R’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/forward’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/reverse’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/output.tsv.biom’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/track.tsv’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/filt_f’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmpa4hb8rt2/filt_r’, ‘0’, ‘0’, ‘220’, ‘200’, ‘2.0’, ‘2.0’, ‘2’, ‘consensus’, ‘1.0’, ‘1’, ‘1000000’]’ died with <Signals.SIGSEGV: 11>.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2cli/commands.py”, line 328, in call
results = action(**arguments)
File “</Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/decorator.py:decorator-gen-475>”, line 2, in denoise_paired
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 245, in bound_callable
output_types, provenance)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 390, in callable_executor
output_views = self._callable(**view_args)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 272, in denoise_paired
" and stderr to learn more." % e.returncode)
Exception: An error was encountered while running DADA2 in R (return code -11), please inspect stdout and stderr to learn more.

Plugin error from dada2:

An error was encountered while running DADA2 in R (return code -11), please inspect stdout and stderr to learn more.

See above for debug info.

1 Like

Thanks @rotifer.

The error is coming up because you appear to be running a different deployment of R than the one shipped with QIIME 2:

This usually happens when your local environment is configured to load R from other sources, before your QIIME 2 environment.

A few commands to debug:

# Command 1
cat ~/.Rprofile # this command might fail, if you don't have an Rprofile. That's fine

# Command 2
# first activate your QIIME 2 environment, then:
R -e '.libPaths()'

# Command 3
# first activate your QIIME 2 environment, then:
env

Please run all three commands and provide the results here. Also, you should start to think about reaching out to your computer’s sysadmin, these kinds of configurations are often defined by the admins that control these machines, so you might want to check in with them, too.

three blocks for the three commands; by the way, I am the administrator of this Mac

Ulis-MacBook-Pro:Tovel16S uli$ cat ~/.Rprofile 

options(repos=c(getOption('repos'),
    CRAN='https://cloud.r-project.org',
    USGS='https://owi.usgs.gov/R'))

Ulis-MacBook-Pro:Tovel16S uli$ 

Ulis-MacBook-Pro:Tovel16S uli$ conda activate qiime2-2020.2
(qiime2-2020.2) Ulis-MacBook-Pro:Tovel16S uli$ R -e '.libPaths()'

R version 3.5.1 (2018-07-02) -- "Feather Spray"
Copyright (C) 2018 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.

.libPaths()
[1] “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/R/library”

(qiime2-2020.2) Ulis-MacBook-Pro:Tovel16S uli$ env
AS=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-as
LDFLAGS=-Wl,-pie -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs -Wl,-rpath,/Users/uli/miniconda3/envs/qiime2-2020.2/lib -L/Users/uli/miniconda3/envs/qiime2-2020.2/lib
AR=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-ar
RSTUDIO_WHICH_R=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/R
CODESIGN_ALLOCATE=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-codesign_allocate
JAVA_LD_LIBRARY_PATH=/Users/uli/miniconda3/envs/qiime2-2020.2/lib/server
TERM_PROGRAM=vscode
HOST=x86_64-apple-darwin13.4.0
TERM=xterm-256color
SHELL=/bin/bash
NM=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-nm
PYTHONNOUSERSITE=/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python*/site-packages/
CPPFLAGS=-D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9 -isystem /Users/uli/miniconda3/envs/qiime2-2020.2/include
TMPDIR=/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/
PAGESTUFF=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-pagestuff
CONDA_SHLVL=1
Apple_PubSub_Socket_Render=/private/tmp/com.apple.launchd.b3my0rmQuC/Render
LIPO=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-lipo
CONDA_PROMPT_MODIFIER=(qiime2-2020.2) 
TERM_PROGRAM_VERSION=1.44.0
SIZE=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-size
NMEDIT=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-nmedit
OLDPWD=/Users/uli/Documents/Qiime
INSTALL_NAME_TOOL=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-install_name_tool
SEGEDIT=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-segedit
GFORTRAN=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-gfortran
ARBHOME=/Users/uli/miniconda3/envs/qiime2-2020.2/lib/arb
SEG_HACK=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-seg_hack
USER=uli
CLANGXX=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-clang++
LIBTOOL=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-libtool
CONDA_BACKUP_HOST=x86_64-apple-darwin13.4.0
CONDA_EXE=/Users/uli/miniconda3/bin/conda
OTOOL=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-otool
SSH_AUTH_SOCK=/private/tmp/com.apple.launchd.y07lac5QzS/Listeners
DEBUG_FORTRANFLAGS=-march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe -march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe -Og -g -Wall -Wextra -fcheck=all -fbacktrace -fimplicit-none -fvar-tracking-assignments
__CF_USER_TEXT_ENCODING=0x1F5:0x0:0x2
CXXFLAGS=-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -std=c++14 -fmessage-length=0 -isystem /Users/uli/miniconda3/envs/qiime2-2020.2/include
CONDA_BUILD_SYSROOT=/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk
STRINGS=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-strings
_CE_CONDA=
CHECKSYMS=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-checksyms
ARBHOME_BACKUP=
PATH=/Users/uli/miniconda3/envs/qiime2-2020.2/bin:/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/3.7/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/ncbi/blast/bin:/opt/X11/bin:/Users/uli/miniconda3/condabin:/Library/Frameworks/Python.framework/Versions/2.7/bin:/Library/Frameworks/Python.framework/Versions/3.7/bin
DEBUG_CXXFLAGS=-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -stdlib=libc++ -fvisibility-inlines-hidden -std=c++14 -fmessage-length=0 -Og -g -Wall -Wextra -isystem /Users/uli/miniconda3/envs/qiime2-2020.2/include
LD=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-ld
CONDA_PREFIX=/Users/uli/miniconda3/envs/qiime2-2020.2
F90=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-gfortran
PWD=/Users/uli/Documents/Qiime/Tovel16S
JAVA_HOME=/Users/uli/miniconda3/envs/qiime2-2020.2
STRIP=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-strip
MPLBACKEND=Agg
F95=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-gfortran
LANG=en_GB.UTF-8
DEBUG_FFLAGS=-march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe -march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe -Og -g -Wall -Wextra -fcheck=all -fbacktrace -fimplicit-none -fvar-tracking-assignments
XPC_FLAGS=0x0
F77=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-gfortran
REDO_PREBINDING=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-redo_prebinding
CXX=x86_64-apple-darwin13.4.0-clang++
CLANG=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-clang
_CE_M=
XPC_SERVICE_NAME=0
SHLVL=2
HOME=/Users/uli
FORTRANFLAGS=-march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe
CFLAGS=-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -isystem /Users/uli/miniconda3/envs/qiime2-2020.2/include
_CONDA_PYTHON_SYSCONFIGDATA_NAME=_sysconfigdata_x86_64_apple_darwin13_4_0
FC=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-gfortran
INDR=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-indr
CONDA_PYTHON_EXE=/Users/uli/miniconda3/bin/python
LOGNAME=uli
JAVA_HOME_CONDA_BACKUP=
CONDA_DEFAULT_ENV=qiime2-2020.2
DEBUG_CFLAGS=-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -Og -g -Wall -Wextra -isystem /Users/uli/miniconda3/envs/qiime2-2020.2/include
RANLIB=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-ranlib
CMAKE_PREFIX_PATH=:/Users/uli/miniconda3/envs/qiime2-2020.2
CC=x86_64-apple-darwin13.4.0-clang
SEG_ADDR_TABLE=/Users/uli/miniconda3/envs/qiime2-2020.2/bin/x86_64-apple-darwin13.4.0-seg_addr_table
DISPLAY=/private/tmp/com.apple.launchd.U9JB8JW5Pf/org.macosforge.xquartz:0
JAVA_LD_LIBRARY_PATH_BACKUP=
LDFLAGS_LD=-pie -headerpad_max_install_names -dead_strip_dylibs -rpath /Users/uli/miniconda3/envs/qiime2-2020.2/lib -L/Users/uli/miniconda3/envs/qiime2-2020.2/lib
R_LIBS_USER=/Users/uli/miniconda3/envs/qiime2-2020.2/lib/R/library/
FFLAGS=-march=nocona -mtune=core2 -ftree-vectorize -fPIC -fstack-protector -O2 -pipe
COLORTERM=truecolor
_=/usr/bin/env
(qiime2-2020.2) Ulis-MacBook-Pro:Tovel16S uli$

Well, everything looks fine there - maybe you accidentally activated multiple conda environments within each other again? I recall we had some issues with that in the past, and would certainly explain the problem reported here. According to your most recent post though, your env looks clean, and should be set. Give it another shot (and pay close attention to the commands you are running), and let us know!

:qiime2:

Hi,
first, many thanks for taking your time to have a look at it
second, it does not work (this is a fresh qiime2-2020.2 environment)
(qiime2-2020.2) Ulis-MacBook-Pro:Tovel16S uli$ qiime dada2 denoise-paired \

–i-demultiplexed-seqs paired-end-demux-trimmed.qza
–p-trunc-len-f 0
–p-trunc-len-r 0
–p-trim-left-f 220
–p-trim-left-r 200
–o-representative-sequences rep-seqs-dada2.qza
–o-table table-dada2.qza
–o-denoising-stats stats-dada2.qza
–verbose
Running external command line application(s). This may print messages to stdout and/or stderr.
The command(s) being run are below. These commands cannot be manually re-run as they will depend on temporary files that no longer exist.

Command: run_dada_paired.R /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/forward /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/reverse /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/output.tsv.biom /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/track.tsv /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/filt_f /var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/filt_r 0 0 220 200 2.0 2.0 2 consensus 1.0 1 1000000

R version 3.6.1 (2019-07-05)
Loading required package: Rcpp

*** caught segfault ***
address 0x18, cause ‘memory not mapped’

Traceback:
1: dyn.load(file, DLLpath = DLLpath, …)
2: library.dynam(lib, package, package.lib)
3: loadNamespace(package, lib.loc)
4: doTryCatch(return(expr), name, parentenv, handler)
5: tryCatchOne(expr, names, parentenv, handlers[[1L]])
6: tryCatchList(expr, classes, parentenv, handlers)
7: tryCatch({ attr(package, “LibPath”) <- which.lib.loc ns <- loadNamespace(package, lib.loc) env <- attachNamespace(ns, pos = pos, deps, exclude, include.only)}, error = function(e) { P <- if (!is.null(cc <- conditionCall(e))) paste(" in", deparse(cc)[1L]) else “” msg <- gettextf(“package or namespace load failed for %s%s:\n %s”, sQuote(package), P, conditionMessage(e)) if (logical.return) message(paste(“Error:”, msg), domain = NA) else stop(msg, call. = FALSE, domain = NA)})
8: library(pkg, character.only = TRUE, logical.return = TRUE, lib.loc = lib.loc, quietly = quietly)
9: .getRequiredPackages2(pkgInfo, quietly = quietly)
10: library(dada2)
11: withCallingHandlers(expr, warning = function(w) invokeRestart(“muffleWarning”))
12: suppressWarnings(library(dada2))
An irrecoverable exception occurred. R is aborting now …
Traceback (most recent call last):
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 257, in denoise_paired
run_commands([cmd])
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 36, in run_commands
subprocess.run(cmd, check=True)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/subprocess.py”, line 418, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command ‘[‘run_dada_paired.R’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/forward’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/reverse’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/output.tsv.biom’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/track.tsv’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/filt_f’, ‘/var/folders/jz/41p1rmwj7gj7g_lpwwsm5vy40000gn/T/tmplv_1bund/filt_r’, ‘0’, ‘0’, ‘220’, ‘200’, ‘2.0’, ‘2.0’, ‘2’, ‘consensus’, ‘1.0’, ‘1’, ‘1000000’]’ died with <Signals.SIGSEGV: 11>.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2cli/commands.py”, line 328, in call
results = action(**arguments)
File “</Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/decorator.py:decorator-gen-475>”, line 2, in denoise_paired
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 245, in bound_callable
output_types, provenance)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/qiime2/sdk/action.py”, line 390, in callable_executor
output_views = self._callable(**view_args)
File “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/python3.6/site-packages/q2_dada2/_denoise.py”, line 272, in denoise_paired
" and stderr to learn more." % e.returncode)
Exception: An error was encountered while running DADA2 in R (return code -11), please inspect stdout and stderr to learn more.

Plugin error from dada2:

An error was encountered while running DADA2 in R (return code -11), please inspect stdout and stderr to learn more.

See above for debug info.

Actually, I think (maybe) to know what is going on: dada2 is unable to merge my forward and reversed reads; maybe return code -11 is pointing to this. I executed dada2 in R and it is not able to merge my sequences; I do not know why because it looks fine, but evidence is against me.
many thanks for your help,
Ulrike

No, I don’t think so - the error message is pretty clear:

You’ll notice that your version of R bounced back to 3.6.1, instead of the 3.5.1 that is shipped with QIIME 2 and verified by you above. I think you might be neglecting to share some “step” or portion of your process with us - the env is being mutated somehow, but there isn’t anything we can do unless you help us out with some more details. Have you attempted to modify QIIME 2 source in your installation? Do you run some kind of custom activation script? If so, maybe there is a bug or faulty logic in it? Are you sure you’re not activating more than one conda env at a time? Another thought - your $PATH env var might not be set up in the right order for miniconda.

I would be very happy if we/you could solve this.
What I am doing:

  • opening visual studio code: open new terminal
  • there I type: conda activate qiime2-2020.2
  • I go to my folder of interest: cd Documents/Qiime/Tovel16S
  • I check my file: qiime tools view demux.qzv
  • q for quitting the view
  • then I execute the command:
    qiime dada2 denoise-paired
    --i-demultiplexed-seqs paired-end-demux-trimmed.qza
    --p-trunc-len-f 0
    --p-trunc-len-r 0
    --p-trim-left-f 220
    --p-trim-left-r 200
    --o-representative-sequences rep-seqs-dada2.qza
    --o-table table-dada2.qza
    --o-denoising-stats stats-dada2.qza
    --verbose
    & the output is the one I sent you.

My miniconda folder looks like the uploaded screenshot

Have you attempted to modify QIIME 2 source in your installation? -> I have no idea what you mean with this: as you may remember I had some trouble installing songbird, so I installed and removed qiime several times (conda env remove -n qiime2-2020.2). Should I remove and re-install again?
best regards,
Ulrike

1 Like

Hmm, looks like something isn't quite adding up here, is it?

Let's try this, please run the following and provide all the output as run:

# start with conda in a "base" state
conda deactivate

which R

conda activate qiime2-2020.2

which R

R -e '.libPaths()'

qiime dada2 denoise-paired \
  --i-demultiplexed-seqs paired-end-demux-trimmed.qza \
  --p-trunc-len-f 0 \
  --p-trunc-len-r 0 \
  --p-trim-left-f 220 \
  --p-trim-left-r 200 \
  --o-representative-sequences rep-seqs-dada2.qza \
  --o-table table-dada2.qza \
  --o-denoising-stats stats-dada2.qza \
  --verbose

Go ahead and give that a shot!

:qiime2:

PS:

I was just wondering if you edited the internal sourcecode of QIIME 2. It happens surprisingly often, and almost always ends with sadness and heartache.

1 Like

here my output:
(base) Ulis-MBP:~ uli$ conda deactivate
Ulis-MBP:~ uli$
Ulis-MBP:~ uli$ which R
/usr/local/bin/R
Ulis-MBP:~ uli$ conda activate qiime2-2020.2
(qiime2-2020.2) Ulis-MBP:~ uli$ which R
/Users/uli/miniconda3/envs/qiime2-2020.2/bin/R
(qiime2-2020.2) Ulis-MBP:~ uli$ R -e ‘.libPaths()’

R version 3.5.1 (2018-07-02) – “Feather Spray”
Copyright © 2018 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.

.libPaths()
[1] “/Users/uli/miniconda3/envs/qiime2-2020.2/lib/R/library”

(qiime2-2020.2) Ulis-MBP:~ uli$ cd Documents/Qiime/Tovel16S
(qiime2-2020.2) Ulis-MBP:Tovel16S uli$ qiime tools view demux.qzv
Press the ‘q’ key, Control-C, or Control-D to quit. This view may no longer be accessible or work correctly after quitting.
(qiime2-2020.2) Ulis-MBP:Tovel16S uli$ qiime dada2 denoise-paired \

–i-demultiplexed-seqs paired-end-demux-trimmed.qza
–p-trunc-len-f 0
–p-trunc-len-r 0
–p-trim-left-f 220
–p-trim-left-r 200
–o-representative-sequences rep-seqs-dada2.qza
–o-table table-dada2.qza
–o-denoising-stats stats-dada2.qza
–verbose

and hurray it worked!!! I thank you so much solving this and I hope also others will find this useful. The outcome, however, is no sequences left but this is something I have to work on.
Again, many many thanks for kind help!!! :+1: :clap:

2 Likes

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.