MicrobeAnnotator: DB build error on step 9
I have tried to create the MicrobeAnnotator with and without Aspera, using the conda installation (v2.0.5) as well as pip installation (v2.0.4) and I keep getting the following errors on step 9 (steps 1-8 worked returned no errors):
With Aspera:
2021-05-03 11:59:58,370 [INFO]: This is MicrobeAnnotator v2.0.5
2021-05-03 11:59:58,371 [INFO]: I will download and format the databases I use.
2021-05-03 11:59:58,371 [INFO]: Creating database folders
2021-05-03 11:59:58,371 [INFO]: Step 9
2021-05-03 11:59:58,371 [INFO]: Downloading protein fasta files using Aspera Connect.
Traceback (most recent call last):
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/bin/microbeannotator_db_builder", line 445, in <module>
main()
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/bin/microbeannotator_db_builder", line 437, in main
single_step, aspera, keep_temp, bin_path)
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/bin/microbeannotator_db_builder", line 175, in database_duilder
refseq_prot = refseq.refseq_fasta_downloader(database_directory)
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/lib/python3.7/site-packages/microbeannotator/database/refseq_data_downloader.py", line 61, in refseq_fasta_downloader
ascp_key = get_aspera_key()
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/lib/python3.7/site-packages/microbeannotator/database/refseq_data_downloader.py", line 277, in get_aspera_key
install_folder = Path(path_to_ascp).parents[1]
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/lib/python3.7/pathlib.py", line 1027, in __new__
self = cls._from_parts(args, init=False)
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/lib/python3.7/pathlib.py", line 674, in _from_parts
drv, root, parts = self._parse_args(args)
File "/gpfs1/scratch/ryan/miniconda3/envs/microbeannotator/lib/python3.7/pathlib.py", line 658, in _parse_args
a = os.fspath(a)
TypeError: expected str, bytes or os.PathLike object, not NoneType
Without Aspera (--no_aspera flag):
2021-04-30 16:48:40,896 [INFO]: This is MicrobeAnnotator v2.0.4
2021-04-30 16:48:40,896 [INFO]: I will download and format the databases I use.
2021-04-30 16:48:40,896 [INFO]: Creating database folders
2021-04-30 16:48:40,897 [INFO]: Step 9
2021-04-30 16:48:40,897 [INFO]: Downloading protein fasta files using wget.
2021-04-30 19:36:28,292 [INFO]: Merging protein files
Traceback (most recent call last):
File "/gpfs1/apps/anaconda/envs/microbeannotator/bin/microbeannotator_db_builder", line 445, in <module>
main()
File "/gpfs1/apps/anaconda/envs/microbeannotator/bin/microbeannotator_db_builder", line 437, in main
single_step, aspera, keep_temp, bin_path)
File "/gpfs1/apps/anaconda/envs/microbeannotator/bin/microbeannotator_db_builder", line 178, in database_duilder
database_directory, threads)
File "/gpfs1/apps/anaconda/envs/microbeannotator/lib/python3.7/site-packages/microbeannotator/database/refseq_data_downloader.py", line 162, in refseq_fasta_downloader_wget
copyfileobj(temp_file,merged_db)
File "/gpfs1/apps/anaconda/envs/microbeannotator/lib/python3.7/shutil.py", line 79, in copyfileobj
buf = fsrc.read(length)
File "/gpfs1/apps/anaconda/envs/microbeannotator/lib/python3.7/gzip.py", line 300, in read1
return self._buffer.read1(size)
File "/gpfs1/apps/anaconda/envs/microbeannotator/lib/python3.7/_compression.py", line 68, in readinto
data = self.read(len(byte_view))
File "/gpfs1/apps/anaconda/envs/microbeannotator/lib/python3.7/gzip.py", line 482, in read
uncompress = self._decompressor.decompress(buf, size)
zlib.error: Error -3 while decompressing data: invalid code lengths set
About this issue
- Original URL
- State: open
- Created 3 years ago
- Reactions: 1
- Comments: 16 (3 by maintainers)
@angeliqueray
I also faced the same issue! While going trough the code/error message, I figured out that the problem was caused by the line number 61 in microbeannotator/database/refseq_data_downloader.py file. “ascp_key = get_aspera_key()”
So, I changed it to: ascp_key = “/home/[username]/.aspera/connect/etc/asperaweb_id_dsa.openssh” # replace [username] with your username.
Did the same thing for line number 186. For some weird reason, this solved the problem for the aspera option.
Hopefully, this helps!
I had the same issue and solved it by adding aspera to path.
Make sure that Aspera added to your path.