bioinformatics-centre / kaiju

Fast taxonomic classification of metagenomic sequencing reads using a protein reference database
http://kaiju.binf.ku.dk
GNU General Public License v3.0
260 stars 68 forks source link

makeDB.sh: wget --show-progress not in old versions of wget #22

Closed boulund closed 7 years ago

boulund commented 7 years ago

I'm on a system using wget version 1.12. Running makeDB.sh on a system with a version of wget older than 1.16 causes the makeDB.sh script to fail. A suggested work around is found here: http://stackoverflow.com/questions/4686464/how-to-show-wget-progress-bar-only/32491843#32491843

Perhaps makeDB.sh could be updated to support older version of wget?

pmenzel commented 7 years ago

Hi,

do you have the latest version of Kaiju from GitHub? I added a check for the availability of that option to wget in commit https://github.com/bioinformatics-centre/kaiju/commit/7689763e5e9a8aa6715478dab9117a7bcdfd40ac.

Peter

boulund commented 7 years ago

Oh, sorry! No I didn't get the latest version! I just used the one on the web page, sorry! :) Then this issue is already solved

boulund commented 7 years ago

Actually, the problem appears to exist even when using the latest version (I pulled the latest version and recompiled just now).

This is the output I get when running makeDB.sh (it's symlinked to kaiju_makeDB.sh in my bin directory. Also, my i18n settings are set to Swedish, sorry):

[fredrikb@m2 proGenomes]$ kaiju_makeDB.sh -p  
Downloading file taxdump.tar.gz               
wget: okänd flagga "--show-progress"          
Användning: wget [FLAGGA]... [URL]...         

Prova "wget --help" för fler flaggor.        

This is my version of wget:

[fredrikb@m2 proGenomes]$ wget --version             
GNU Wget 1.12 byggd på linux-gnu.                                     

+digest +ipv6 +nls +ntlm +opie +md5/openssl +https -gnutls +openssl   
-iri                                                                  

Wgetrc:                                                               
    /etc/wgetrc (system)                                              
Lokalanpassning: /usr/share/locale                                    
Kompilering: gcc -DHAVE_CONFIG_H -DSYSTEM_WGETRC="/etc/wgetrc"        
    -DLOCALEDIR="/usr/share/locale" -I. -I../lib -O2 -g -pipe -Wall   
    -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector            
    --param=ssp-buffer-size=4 -m64 -mtune=generic -fno-strict-aliasing
Länkning: gcc -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions 
    -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic   
    -fno-strict-aliasing -Wl,-z,relro -lssl -lcrypto                  
    /usr/lib64/libssl.so /usr/lib64/libcrypto.so -ldl -lrt ftp-opie.o 
    openssl.o http-ntlm.o gen-md5.o ../lib/libgnu.a                   

Copyright © 2009 Free Software Foundation, Inc.                       
Licens GPLv3+: GNU GPL version 3 eller senare                         
<http://www.gnu.org/licenses/gpl.html>.                               
Det här är fri programvara: du får fritt ändra och distribuera den.   
Det finns INGEN GARANTI så långt som lagen tillåter.                  

Ursprungligen skrivet av Hrvoje Niksic <hniksic@xemacs.org>.          
Underhålls för närvarande av Micah Cowan <micah@cowan.name>.          
Skicka felrapporter och frågor till <bug-wget@gnu.org>.               
Skicka synpunkter på översättningen till <tp-sv@listor.tp-sv.se>.     

It's no problem working around the bug, I just edited makeDB.sh to remove the --show-progress flag from the wget command on line 113, but it would make it easier to use for others if this could be fixed.

pmenzel commented 7 years ago

Haha, I see that the problem is the Swedish localisation.. Your wget says okänd flagga, while makeDB.sh looks for unrecognized option. :)

I will try to change it to the solution shown in that SO post that you linked.

Många tack!

Hejdo, Peter

boulund commented 7 years ago

Haha. I must be getting tired for not spotting that when it was on a line just above the one where I edited. Ah well. At least we know there's still some tweaking to be done around this :)

pmenzel commented 7 years ago

Would you please test if that commit fixes the issue with makeDB.sh for your Swedish system? thanks!

boulund commented 7 years ago

Works fine now! But it seems like an esoteric way of solving it, why not just check if wget version is newer than 1.16? Not that I'm complaining; it works as intended :)

pmenzel commented 7 years ago

thanks for testing!

(testing the version number would not be as straight-forward as grepping the name of the option)