PacificBiosciences / HiFi-16S-workflow

Nextflow pipeline to analyze PacBio HiFi full-length 16S data
BSD 3-Clause Clear License
59 stars 15 forks source link

nextflow v23.10 compatibility #41

Closed blumeria closed 10 months ago

blumeria commented 10 months ago

I updated my nextflow installation to version 23.10 and now I get the error below when running the test data (nextflow run main.nf --input data/test_data/test_sample.tsv --metadata data/test_data/test_metadata.tsv -profile singularity --outdir testdata --publish_dir_mode copy). Does anybody experience the same issue? With nextflow v23.4.2 and v23.4.4 everything works fine. I tested it on two different HPC cluster, one running with apptainer version 1.2.4-1.el7 and the other with 1.1.3.-1.el7.


  task: name=pb16S:import_qiime2 (1); work-dir=/data/groups/ngsp/04_pb_16S/pb-16S-nf/work/6c/319c971e5fa979bb0fd3897df69aba
  error [nextflow.exception.ProcessFailedException]: Process `pb16S:import_qiime2 (1)` terminated with an error exit status (1)
Nov-16 13:30:30.464 [Task monitor] ERROR nextflow.processor.TaskProcessor - Error executing process > 'pb16S:import_qiime2 (1)'
Caused by:
  Process `pb16S:import_qiime2 (1)` terminated with an error exit status (1)

Command executed:

  # Make sure path is absolute
  awk -v wdir="$(pwd)/" -F$'    ' '{if (NR>1){print $1,wdir$2} else {print $0}}' OFS=$' ' samplefile.txt > sample_list.txt
  qiime tools import --type 'SampleData[SequencesWithQuality]'     --input-path sample_list.txt     --output-path samples.qza     --input-format SingleEndFastqManifestPhred33V2

Command exit status:
  1

Command output:
  (empty)

Command error:
  INFO:    Environment variable SINGULARITYENV_TMPDIR is set, but APPTAINERENV_TMPDIR is preferred
  INFO:    Environment variable SINGULARITYENV_NXF_TASK_WORKDIR is set, but APPTAINERENV_NXF_TASK_WORKDIR is preferred
  INFO:    Environment variable SINGULARITYENV_NXF_DEBUG is set, but APPTAINERENV_NXF_DEBUG is preferred
  Matplotlib created a temporary config/cache directory at /tmp/matplotlib-330of3d2 because the default path (/home/XXX/.config/matplotlib) is not a writable directory; it is highly recommended to set the MPLCONFIGDIR environment variable to a writable directory, in particular to speed up the import of Matplotlib and to better support multiprocessing.
  Traceback (most recent call last):
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/q2cli/builtin/tools.py", line 157, in import_data
      artifact = qiime2.sdk.Artifact.import_data(type, input_path,
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/qiime2/sdk/result.py", line 287, in import_data
      view_type = qiime2.sdk.parse_format(view_type)
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/qiime2/sdk/util.py", line 88, in parse_format
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/qiime2/sdk/plugin_manager.py", line 67, in __new__
      self._init(add_plugins=add_plugins)
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/qiime2/sdk/plugin_manager.py", line 105, in _init
      plugin = entry_point.load()
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/pkg_resources/__init__.py", line 2477, in load
      return self.resolve()
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/pkg_resources/__init__.py", line 2483, in resolve
      module = __import__(self.module_name, fromlist=['__name__'], level=0)
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/q2_diversity/__init__.py", line 11, in <module>
      from ._beta import (beta, beta_phylogenetic, bioenv,
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/q2_diversity/_beta/__init__.py", line 13, in <module>
      from ._beta_rarefaction import beta_rarefaction
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/q2_diversity/_beta/_beta_rarefaction.py", line 23, in <module>
      from .._ordination import pcoa
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/q2_diversity/_ordination.py", line 13, in <module>
      import umap as up
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/umap/__init__.py", line 2, in <module>
      from .umap_ import UMAP
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/umap/umap_.py", line 41, in <module>
      from umap.layouts import (
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/umap/layouts.py", line 40, in <module>
      def rdist(x, y):
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/numba/core/decorators.py", line 212, in wrapper
      disp.enable_caching()
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/numba/core/dispatcher.py", line 863, in enable_caching
      self._cache = FunctionCache(self.py_func)
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/numba/core/caching.py", line 601, in __init__
      self._impl = self._impl_class(py_func)
    File "/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/numba/core/caching.py", line 337, in __init__
      raise RuntimeError("cannot cache function %r: no locator available "
  RuntimeError: cannot cache function 'rdist': no locator available for file '/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/umap/layouts.py'

  An unexpected error has occurred:

    cannot cache function 'rdist': no locator available for file '/opt/conda/envs/qiime2-2023.2/lib/python3.8/site-packages/umap/layouts.py'

  See above for debug info.

Work dir:
  /data/groups/XXX/04_pb_16S/pb-16S-nf/work/6c/319c971e5fa979bb0fd3897df69aba```
blumeria commented 10 months ago

the solution was to mount the /home directory in the nextflow.config

singularity.runOptions = "--bind /home/XXXX"