KeyError: 'assembly_accession'
biotemon opened this issue · 1 comments
biotemon commented
I am trying to run the following line:
ncbi-genome-download bacteria -l 'all' -g 'Pseudomonas' -m metadata.txt
But I get this error:
Traceback (most recent call last):
File "/Users/tito_miniconda/opt/miniconda3/bin/ncbi-genome-download", line 8, in <module>
sys.exit(main())
File "/Users/tito_miniconda/opt/miniconda3/lib/python3.8/site-packages/ncbi_genome_download/__main__.py", line 26, in main
ret = args_download(args)
File "/Users/tito_miniconda/opt/miniconda3/lib/python3.8/site-packages/ncbi_genome_download/core.py", line 174, in args_download
return config_download(config)
File "/Users/tito_miniconda/opt/miniconda3/lib/python3.8/site-packages/ncbi_genome_download/core.py", line 193, in config_download
download_candidates = select_candidates(config)
File "/Users/tito_miniconda/opt/miniconda3/lib/python3.8/site-packages/ncbi_genome_download/core.py", line 290, in select_candidates
for entry in filter_entries(entries, config):
File "/Users/tito_miniconda/opt/miniconda3/lib/python3.8/site-packages/ncbi_genome_download/core.py", line 336, in filter_entries
if not config.is_compatible_assembly_accession(entry['assembly_accession']):
KeyError: 'assembly_accession'
What can I do?
kblin commented
Hi there. This sounds like this might be caused by the layout change in the assembly accession file from NCBI almost a year ago. I've released ncbi-genome-download 0.3.2 to address this 11 months ago, please make sure you're on at least that version.
Please leave a comment if you are on a recent version and the problem still exists.