Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--arg_rgi_db not working in v. 2.0.0 #436

Closed
amizeranschi opened this issue Jan 11, 2025 · 2 comments · Fixed by #437
Closed

--arg_rgi_db not working in v. 2.0.0 #436

amizeranschi opened this issue Jan 11, 2025 · 2 comments · Fixed by #437
Assignees
Labels
bug Something isn't working

Comments

@amizeranschi
Copy link

Hi,

The parameter --arg_rgi_db doesn't seem to work as expected in v. 2.0.0 of the pipeline. The error looks like this:

Command error:
  Matplotlib created a temporary cache directory at /tmp/matplotlib-02ng_iet because the default path (/.config/matplotlib) is not a writable directory; it is highly recommended to set the MPLCONFIGDIR environment variable to a writable directory, in particular to speed up the import of Matplotlib and to better support multiprocessing.
  mkdir: can't create directory 'card_database_processed': File exists

The following code should reproduce the error:

mkdir ~/test-funcscan-error
cd ~/test-funcscan-error

nextflow run nf-core/funcscan -r 2.0.0 \
-profile docker,test \
--run_amp_screening false \
--run_arg_screening \
--arg_skip_abricate \
--arg_skip_amrfinderplus \
--arg_skip_deeparg \
--arg_skip_fargene \
--run_bgc_screening false \
--save_db \
--outdir save-DBs

nextflow run nf-core/funcscan -r 2.0.0 \
-profile docker,test \
--run_amp_screening false \
--run_arg_screening \
--arg_skip_abricate \
--arg_skip_amrfinderplus \
--arg_skip_deeparg \
--arg_skip_fargene \
--arg_rgi_db ~/test-funcscan-error/save-DBs/databases/rgi/card_database_processed \
--run_bgc_screening false \
--save_db \
--outdir output-funcscan
@amizeranschi amizeranschi added the bug Something isn't working label Jan 11, 2025
@amizeranschi amizeranschi changed the title --arg_rgi_db error not working in v. 2.0.0 --arg_rgi_db not working in v. 2.0.0 Jan 12, 2025
@jasmezz jasmezz self-assigned this Jan 14, 2025
@jasmezz
Copy link
Collaborator

jasmezz commented Jan 14, 2025

Ok this behaviour is due to the fact that the CARD preprocessing module rgi/cardannotation is executed even if you provide an already preprocessed database. With the --save_db option, funcscan provides you both, preprocessed and non-preprocessed database folder. You can just use the non-processed one.

Usually, the double-preprocessing does not result in an error, that's why we decided to process the database always to be on the safe site. But with the pipeline-chaining, identical folder names would lead to overwriting, therefore causing the error. Thanks for reporting!

I'll create a fix to not execute the preprocessing module if the CARD database folder is recycled from a previous pipeline run.

@jasmezz jasmezz linked a pull request Jan 15, 2025 that will close this issue
11 tasks
@jasmezz
Copy link
Collaborator

jasmezz commented Jan 16, 2025

Solved by #437

@jasmezz jasmezz closed this as completed Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants