nextgenusfs / funannotate

Eukaryotic Genome Annotation Pipeline
http://funannotate.readthedocs.io
BSD 2-Clause "Simplified" License
317 stars 83 forks source link

funannotate annotate uses $FUNANNOTATE_DB over -d /path/to/databases for go.obo #1059

Open mjacksonhill opened 1 month ago

mjacksonhill commented 1 month ago

Funannotate 1.8.17, discovered this issue while using a container version. If $FUNANNOTATE_DB is set to one location and the -d command line option is set to another, funannotate will look for go.obo in $FUNANNOTATE_DB instead of the location specified at the command line. (an edge case, but discovered as I migrated between conda funannotate-1.8.15 and singularity funannotate-1.8.17)

Not sure if this is intended-- my guess was it is not, since for the most part the other parts of funannotate annotate seem to prioritize the command line option.

hyphaltip commented 1 month ago

the problem is the code is buried in the library module which only parses this file at the step of writing TBL file - it would be better to set the DB path as a state variable in the library object.

There's probably more refactoring effort better put into funannotate2 right now that figuring out how to better expose this variable outside. Or else to just ensure env variable is set during the program running when -d is passed.

Will see what jon thinks.

mjacksonhill commented 1 month ago

Totally understandable-- just wanted to put it on the record somewhere even though it's a small thing!