poreCov icon indicating copy to clipboard operation
poreCov copied to clipboard

Singularity container execution of pangolin crashes with recent nextflow versions

Open Krannich479 opened this issue 9 months ago • 9 comments

Hi, I noticed that poreCov crashes when running pangolin via singularity and a reasonably modern nextflow version. It seems that recent updates in the path mounting defaults of nextflow broke the default behavior of poreCov test profiles when using Singularity. More precise, when using the command

nextflow run poreCov.nf -profile test_fastq,slurm,singularity --update

with nextflow 23.10.1 and poreCov 1.9.4 I end up with

[f3/91e3e5] NOTE: Process `determine_lineage_wf:pangolin (1)` terminated with an error exit status (1) -- Execution is retried (1)
ERROR ~ Error executing process > 'determine_lineage_wf:pangolin (1)'

Caused by:
  Process `determine_lineage_wf:pangolin (1)` terminated with an error exit status (1)

Command executed:

  pangolin --skip-scorpio -t 4 SARSCoV2.consensus.fasta

  mv lineage_report.csv lineage_report_SARSCoV2.csv

  find . -name "*.csv" -size  0 -print -delete

Command exit status:
  1

Command output:
  ****
  Pangolin skipping scorpio steps.
  ****
  ****
  Pangolin running in usher mode.
  ****
  Maximum ambiguity allowed is 0.3.
  ****
  Query file:ameSARSCoV2.consensus.fasta
  ****
  Data files found:
  usher_pb:     /opt/conda/lib/python3.7/site-packages/pangolin_data/data/lineageTree.pb
  ****

Command error:
  Traceback (most recent call last):
    File "/opt/conda/lib/python3.7/site-packages/snakemake/__init__.py", line 642, in snakemake
      latency_wait=latency_wait,
    File "/opt/conda/lib/python3.7/site-packages/snakemake/workflow.py", line 242, in __init__
      self.sourcecache = SourceCache()
    File "/opt/conda/lib/python3.7/site-packages/snakemake/sourcecache.py", line 358, in __init__
      os.makedirs(self.cache, exist_ok=True)
    File "/opt/conda/lib/python3.7/os.py", line 213, in makedirs
      makedirs(head, exist_ok=exist_ok)
    File "/opt/conda/lib/python3.7/os.py", line 213, in makedirs
      makedirs(head, exist_ok=exist_ok)
    File "/opt/conda/lib/python3.7/os.py", line 213, in makedirs
      makedirs(head, exist_ok=exist_ok)
    [Previous line repeated 1 more time]
    File "/opt/conda/lib/python3.7/os.py", line 223, in makedirs
      mkdir(name, mode)
  OSError: [Errno 30] Read-only file system: '/home/<myHPCusername>'

Additional Info:

The same command works fine and tests finish if I use nextflow 21.04.0. @MarieLataretu found these update notes that seem on point for this issue: https://github.com/nextflow-io/nextflow/blob/d8f8bf56cfe79dc05db7c149dafa0174717ae7f4/docs/container.md?plain=1#L580 https://github.com/nextflow-io/nextflow/blob/d8f8bf56cfe79dc05db7c149dafa0174717ae7f4/docs/container.md?plain=1#L584

Krannich479 avatar May 27 '24 10:05 Krannich479