artic-network / fieldbioinformatics

The ARTIC field bioinformatics pipeline
MIT License
112 stars 68 forks source link

Command failed:align_trim #81

Closed gezthxbio closed 3 years ago

gezthxbio commented 3 years ago

Hi I'm trying to run the artic pipeline on a minION dataset, r9.4.1 the earlier versions of this pipeline worked (https://github.com/artic-network/artic-ncov2019), i updated to this repository (ver: 1.2.1) and "align_trim" step

Command failed:align_trim --normalise 200 /Compute/CovidSeq/minION/artic-ncov2019/primer_schemes/nCoV-2019/V3/nCoV-2019.scheme.bed --start --remove-incorrect-pairs --report barcode01.alignreport.txt < barcode01.sorted.bam 2> barcode01.alignreport.er | samtools sort -T barcode01 - -o barcode01.trimmed.rg.sorted.bam

started giving this error:

samtools sort: failed to read header from "-"

cat barcode01.alignreport.er

Traceback (most recent call last):
  File "/staging/appdir/anaconda3/bin/align_trim", line 33, in <module>
    sys.exit(load_entry_point('artic==1.2.1', 'console_scripts', 'align_trim')())
  File "/staging/appdir/anaconda3/lib/python3.8/site-packages/artic-1.2.1-py3.8.egg/artic/align_trim.py", line 296, in main
    go(args)
  File "/staging/appdir/anaconda3/lib/python3.8/site-packages/artic-1.2.1-py3.8.egg/artic/align_trim.py", line 169, in go
    bam_header = infile.header.copy().to_dict()
AttributeError: 'dict' object has no attribute 'to_dict'
gezthxbio commented 3 years ago

re-installed the whole pipeline,

conda remove --name artic --all
git clone https://github.com/artic-network/fieldbioinformatics
cd fieldbioinformatics
conda env create -f environment.yml
conda activate artic
python setup.py install

it's working now.