oschwengers / bakta

Rapid & standardized annotation of bacterial genomes, MAGs & plasmids
GNU General Public License v3.0
411 stars 44 forks source link

Option to Skip the AMR detection step #268

Open abelTan131 opened 5 months ago

abelTan131 commented 5 months ago

Is your feature request related to an existing issue or bug? Briefly reference any existing issues this is related to.

I run my file and got: Traceback (most recent call last): File "/opt/conda/bin/bakta", line 8, in sys.exit(main()) File "/opt/conda/lib/python3.8/site-packages/bakta/main.py", line 275, in main expert_amr_found = exp_amr.search(cdss, cds_aa_path) File "/opt/conda/lib/python3.8/site-packages/bakta/expert/amrfinder.py", line 47, in search raise Exception(f"amrfinder error! error code: {proc.returncode}. Please, try 'amrfinder_update --force_update --database {amrfinderplus_db_path}' to update AMRFinderPlus's internal database.") Exception: amrfinder error! error code: 1. Please, try 'amrfinder_update --force_update --database /tllhome/abel/bakta/db-light/amrfinderplus-db' to update AMRFinderPlus's internal database.

Is your new feature related to a general problem? Please provide us with a concise description of what the problem is:

Describe the solution you'd like A clear and concise description of what you want to happen. Option to skip the AMR detection step, so I dont get this error.

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or information about your feature request here.

gracehm commented 5 months ago

Hi, I just wanted to add that we are also facing the same issue, only as of yesterday. We haven't been able to solve it yet, but I wanted to add in case it is a potential update issue.

oschwengers commented 5 months ago

Hi @abelTan131 , @gracehm , thanks for reporting. We also see these issues with the AMRFinderPlus update from time to time. However, I'm still puzzled what causes these effects. I have updated the DB download routine and relaxed file permissions which are set during the download/update. Maybe this helps a bit here. This is active in the new [v1.9.2]() patch release. I also published a huge database update this week [v5.1](). You might want to try this one.

FYI: the amrfinder_update --force_update --database <path-to-bakta-db>/amrfinderplus-db/ command as suggested by the Bakta error output did the job in my cases.

aldertzomer commented 4 months ago

Same problem here. Will try the update. Does it have to do with this amrfinderplus issue: https://github.com/ncbi/amr/issues/89 ?

oschwengers commented 3 months ago

Hi @aldertzomer, sorry for the late reply. No, the issue you've referenced is quite old and is already fixed IMHO. So, I don't think that this error is related to that issue. I rather see this caused by the new AMRFinderPlus DB version which is not compatible with former versions. Hence, an update of Bakta with the newest AMRFinderPlus version and an DB update should solve this.

DanielleMStevens commented 3 months ago

I was having the same issue. My fix was updating both Bakta (v1.9.3) and AMRFinderPlus with both:

amrfinder_update --force_update --database <path-to-bakta-db>/amrfinderplus-db/
amrfinder --force_update

Though the first few tries didn't work until I updated the read/write/execute permissions of the amrfinderplus-db directory. Can't say if its the same issue but may be something to check.