jaleezyy / covid-19-signal

Files and methodology pertaining to the sequencing and analysis of SARS-CoV-2, causative agent of COVID-19.
MIT License
30 stars 25 forks source link

Pipeline fails at run_lineage_assignment when trying to use Nextclade version 3.0.0 #138

Closed PierreLyons closed 9 months ago

PierreLyons commented 9 months ago

The pipeline fails at the run_lineage_assignment step when attempting to use Nextclade version 3.0.0 (either explicitly set in the config.yaml file, or left blank) with the following error message:

Downloading latest Nextclade sars-cov-2 dataset for reference MN908947!

Nextclade and datasets now: Nextclade: 3.0.0 Reference: MN908947 Dataset: sars-cov-2 Dataset version: Latest as of 2024-01-24

Running Pangolin... Running Nextclade... Unknown version of nextclade! Traceback (most recent call last): File "/home/vitalite-dev/covid-19-signal/scripts/assign_lineages.py", line 368, in nextclade = run_nextclade(args.input_genomes, nextclade_dataset, args.threads, nextclade_version) File "/home/vitalite-dev/covid-19-signal/scripts/assign_lineages.py", line 225, in run_nextclade raise FileNotFoundError(f"{str(output_file)} not created, check " FileNotFoundError: tmp_nextclade/nextclade_temp_1706116264.9941878.csv not created, check nextclade install

jaleezyy commented 9 months ago

Given the larger scale update between Nextclade 2 and 3, adjustments may take some time as I look into it. I presume specifying any version of Nextclade 2 (i.e., 2.12 or 2.14) within the config.yaml should allow for SIGNAL to run to completion in the meanwhile.

Thanks for your patience!

PierreLyons commented 9 months ago

Thanks for the quick response.

Unfortunately, downgrading via setting a different Nextclade version number in the config.yaml file doesn't seem to work for me. The pipeline ignores the version I put in, and instead the latest version of Nextclade will be installed and used, causing the same error.

I've managed to patch the issue by modifying the scripts/assign_lineage.py file like so:

  1. comment out line 81
  2. replace softrequest variable with software_ver in the if/else statement at lines 83, 84, 86, and 87.

This seems to allow the correct version of Nextclade to be run on my local setup.

Thanks

jaleezyy commented 9 months ago

Gotcha! I'll double-check that segment as I adjust for Nextclade v3 and its updated output (so while Nextclade 3 wouldn't run with this version regardless, you'd likely come across subsequent errors if it did).

ETA for patch: Thursday, January 25, 2024

jaleezyy commented 9 months ago

SIGNAL v1.6.3 brings Nextclade V3 support and should address the user-specified version install issues brought up when downgrading Nextclade.

Let me know if there are any other issues!