BCCDC-PHL / FluViewer

Tool for generating influenza A virus genome sequences from FASTQ data
https://bccdc-phl.github.io/FluViewer/
4 stars 1 forks source link

Incompatibility between `spades=3.15.*` and `setuptools=70.*` #37

Closed dfornika closed 1 month ago

dfornika commented 1 month ago

We're experiencing some issues related to come sort of incompatibility between python setuptools and spades, for the versions of those components that are being installed in our FluViewer environment in our BCCDC-PHL/fluviewer-nf pipeline:

'dict' object has no attribute 'add' 
Traceback (most recent call last):
  File "bin/spades.py", line 626, in main
    pipeline.generate_configs(cfg, spades_home, tmp_configs_dir)
  File "share/spades/spades_pipeline/stages/pipeline.py", line 43, in generate_configs
    stage.generate_config(cfg)
  File "share/spades/spades_pipeline/stages/spades_stage.py", line 379, in generate_config
    stage.generate_config(self.cfg)
  File "share/spades/spades_pipeline/stages/spades_iteration_stage.py", line 144, in generate_config
    dir_util.copy_tree(os.path.join(self.tmp_configs_dir, "debruijn"), dst_configs, preserve_times=False)
  File "lib/python3.9/site-packages/setuptools/_distutils/dir_util.py", line 146, in copy_tree
    mkpath(dst, verbose=verbose)
  File "lib/python3.9/site-packages/setuptools/_distutils/dir_util.py", line 82, in mkpath
    _path_created.add(abs_head) 
AttributeError: 'dict' object has no attribute 'add'

One possible solution could be to use spades v4.0.0 which is the latest release. But if we want to pursue that we should evaluate whether the assemblies produced by that version of spades are equivalent to the ones produced by spades v3.15.3, the version currently tagged in our environment.yml file:

https://github.com/BCCDC-PHL/FluViewer/blob/455ae76207a30b00a0997140f85d406b2854f592/environment.yaml#L12

dfornika commented 1 month ago

I've found an alternative solution for this issue, which would just involve pinning setuptools=69 in our environment.yml file. That would be a more conservative change and wouldn't require extensive comparisons to other FluViewer outputs so we should do that before seriously considering updating spades to the v4 series.