nf-core / viralrecon

Assembly and intrahost/low-frequency variant calling for viral samples
https://nf-co.re/viralrecon
MIT License
118 stars 108 forks source link

Temp file problem in VARIANTS_IVAR:BCFTOOLS_SORT #415

Open Paururo opened 8 months ago

Paururo commented 8 months ago

Description of the bug

Hello, I am running the test command to launch the pipeline on an HPC machine, but with version 2.6 I am having issues as it fails at the NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE) step. It reports an error that it cannot create a temporary file in my temp folder, which is empty and has write permissions. I saw this issue (https://github.com/nf-core/viralrecon/issues/328) and did what was recommended, adding a config file to change the path of the temporary directory with the following content: ------------{custom.config}------------ process { withName: '.:.:VARIANTS_IVAR:BCFTOOLS_SORT' { ext.args = '--temp-dir ./' } } ------------{custom.config}------------ However, the error persists at the same step, stating that it cannot find the vcf file. If I run the same test command with version 2.4.1, it works without any problems. Any ideas on how to solve this would be appreciated, as it's unfortunate that the latest version isn't working.

Command used and terminal output

With the command:
nextflow run nf-core/viralrecon -profile test,singularity --outdir prueba_viral
Terminal output:
-[nf-core/viralrecon] Pipeline completed with errors-
ERROR ~ Error executing process > 'NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE)'

Caused by:
  Process `NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE)` terminated with an error exit status (255)

Command executed:

  bcftools \
      sort \
      --output SAMPLE1_PE.vcf.gz \
      --output-type z \
      SAMPLE1_PE.vcf

  cat <<-END_VERSIONS > versions.yml
  "NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT":
      bcftools: $(bcftools --version 2>&1 | head -n1 | sed 's/^.*bcftools //; s/ .*$//')
  END_VERSIONS

Command exit status:
  255

Command output:
  (empty)

Command error:
  mkdtemp(/scr/ruizro/tmp/bcftools.FKVBhi) failed: No such file or directory

Work dir:
  /home/ruizro/work/12/21875be8c258a88ce9e39e720cfc42

With the command: 
nextflow run nf-core/viralrecon -profile test,singularity --outdir prueba_viral -c custom.config

Terminal output:
  task: name=NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE); work-dir=/home/ruizro/work/66/6a66d0f7510e869e8142482ef5d6c5
  error [nextflow.exception.MissingFileException]: Missing output file(s) `*.{vcf,vcf.gz,bcf,bcf.gz}` expected by process `NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE)` (note: input files are not included in the default matching set)
Jan-29 20:19:43.456 [Task monitor] ERROR nextflow.processor.TaskProcessor - Error executing process > 'NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE)'

Caused by:
  Missing output file(s) `*.{vcf,vcf.gz,bcf,bcf.gz}` expected by process `NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT (SAMPLE1_PE)` (note: input files are not included in the default matching set)

Command executed:

  bcftools \
      sort \
      --output SAMPLE1_PE.vcf \
      --temp-dir ./ \
      SAMPLE1_PE.vcf

  cat <<-END_VERSIONS > versions.yml
  "NFCORE_VIRALRECON:ILLUMINA:VARIANTS_IVAR:BCFTOOLS_SORT":
      bcftools: $(bcftools --version 2>&1 | head -n1 | sed 's/^.*bcftools //; s/ .*$//')
  END_VERSIONS

Command exit status:
  0

Command output:
  (empty)

Command error:
  Writing to ./kzRuuA
  Merging 1 temporary files
  Cleaning
  Done

Work dir:
  /home/ruizro/work/66/6a66d0f7510e869e8142482ef5d6c5

Relevant files

No response

System information

bioinformatica-isp commented 8 months ago

same error here!