Tasks
Actions
Resume
To resume this run, resubmit with same or fixed code. You can also change other parameters but that will affect caching behavior.
-resume d93d7407-92c2-41b4-8a38-526357e3b851 -name mipeters-sarek-optitype-subsample10k-glpk-697d0fdc
Error Report
Error executing process > 'NFCORE_SAREK:SAREK:CRAM_HLATYPING_ALL:CRAM_FILTER_HLA (1029_BBCQ-N1-BDNA-1_2375WFLT3_s21)'
Caused by:
Process `NFCORE_SAREK:SAREK:CRAM_HLATYPING_ALL:CRAM_FILTER_HLA (1029_BBCQ-N1-BDNA-1_2375WFLT3_s21)` terminated with an error exit status (1)
Command executed:
# Detect input type and set up appropriate pipeline
# CRAM requires samtools conversion first; BAM can be read directly by sambamba
if [[ "1029_BBCQ-N1-BDNA-1_2375WFLT3_s21.recalibrated.bam" == *.cram ]]; then
INPUT_CMD="samtools view -h -b --reference Homo_sapiens_assembly38.fasta 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21.recalibrated.bam"
else
INPUT_CMD="cat 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21.recalibrated.bam"
fi
MAX_READS=10000
# Filter reads and sort by name
eval $INPUT_CMD | \
sambamba view \
-f bam -h \
-t 18 \
-F "unmapped or mate_is_unmapped or (ref_name == 'chr6' and position > 29844528 and position < 33100696) or ref_name =~ /^HLA|chr6.*alt/" \
/dev/stdin | \
sambamba sort \
-n \
-t 18 \
-o filtered.bam \
/dev/stdin
# Count read pairs and optionally subsample
TOTAL_READS=$(samtools view -c filtered.bam)
TOTAL_PAIRS=$((TOTAL_READS / 2))
echo "HLA filter: $TOTAL_PAIRS read pairs extracted"
if [[ $MAX_READS -gt 0 && $TOTAL_PAIRS -gt $MAX_READS ]]; then
# Calculate subsample fraction (add 5% buffer to account for sampling variance)
FRAC=$(awk -v max=$MAX_READS -v total=$TOTAL_PAIRS 'BEGIN {printf "%.4f", (max * 1.05) / total}')
echo "Subsampling to ~$MAX_READS pairs (fraction: $FRAC)"
samtools view -s 42.$FRAC -b filtered.bam | \
samtools fastq \
-@ 18 \
-1 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21_R1.fq.gz \
-2 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21_R2.fq.gz \
-0 /dev/null \
-s /dev/null \
-
else
# No subsampling needed
samtools fastq \
-@ 18 \
-1 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21_R1.fq.gz \
-2 1029_BBCQ-N1-BDNA-1_2375WFLT3_s21_R2.fq.gz \
-0 /dev/null \
-s /dev/null \
filtered.bam
fi
rm -f filtered.bam
cat <<-END_VERSIONS > versions.yml
"NFCORE_SAREK:SAREK:CRAM_HLATYPING_ALL:CRAM_FILTER_HLA":
sambamba: $(sambamba --version 2>&1 | head -1 | awk '{print $2}')
samtools: $(samtools --version | head -1 | awk '{print $2}')
END_VERSIONS
Command exit status:
1
Command output:
HLA filter: 1278131 read pairs extracted
Subsampling to ~10000 pairs (fraction: 0.0082)
Command error:
sambamba 1.0.1
by Artem Tarasov and Pjotr Prins (C) 2012-2023
LDC 1.39.0 / DMD v2.109.1 / LLVM17.0.6 / bootstrap LDC - the LLVM D compiler (1.39.0)
sambamba 1.0.1
by Artem Tarasov and Pjotr Prins (C) 2012-2023
LDC 1.39.0 / DMD v2.109.1 / LLVM17.0.6 / bootstrap LDC - the LLVM D compiler (1.39.0)
samtools view: Incorrect sampling argument "42.0.0082"
Failed to read header for "-"
Work dir:
s3://natera-rnd-pltf-dev-nextflow-scratch-01/work/ff/e6d43cab4e810b9b5c95d0d563b382
Container:
community.wave.seqera.io/library/sambamba_samtools:0966924e22545fbe
Tip: when you have fixed the problem you can continue the execution adding the option `-resume` to the run command line
Workflow
- Language / Cluster
- Nextflow / pltf-dev
- Session ID
- d93d7407-92c2-41b4-8a38-526357e3b851
- Source
- /code/main.nf
- Work Dir
- s3://natera-rnd-pltf-dev-nextflow-scratch-01/work
- Submitted By
- mipeters
- Resumed
- No
Cost and Runtime
- Status
- failed
- Cost
- $3.49
- Outputs
- 1.6 GB
- Started
- Jan 30, 2026 12:10 PM
- Completed
- Jan 30, 2026 12:25 PM
- Duration
- 15m 21s
- Post-workflow Transfer
- 0s
- Exit Status
- 1
- Peak Tasks / CPU / Mem
- 13 / 52 / 244.0 GB