Skip to content

Commit

Permalink
Update the p7_hmmfile API for opening HMM files
Browse files Browse the repository at this point in the history
  • Loading branch information
althonos committed Aug 16, 2023
1 parent a712fd6 commit 0f92f32
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
6 changes: 2 additions & 4 deletions include/libhmmer/p7_hmmfile.pxd
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,8 @@ cdef extern from "hmmer.h" nogil:
char[eslERRBUFSIZE] errbuf


int p7_hmmfile_OpenE (const char *filename, char *env, P7_HMMFILE **ret_hfp, char *errbuf) except *
int p7_hmmfile_OpenENoDB(const char *filename, char *env, P7_HMMFILE **ret_hfp, char *errbuf) except *
int p7_hmmfile_Open (const char *filename, char *env, P7_HMMFILE **ret_hfp) except * # Deprecated
int p7_hmmfile_OpenNoDB (const char *filename, char *env, P7_HMMFILE **ret_hfp) except * # Deprecated
int p7_hmmfile_Open (const char *filename, char *env, P7_HMMFILE **ret_hfp, char *errbuf) except *
int p7_hmmfile_OpenNoDB (const char *filename, char *env, P7_HMMFILE **ret_hfp, char *errbuf) except *
int p7_hmmfile_OpenBuffer(const char *buffer, int size, P7_HMMFILE **ret_hfp) except *
void p7_hmmfile_Close(P7_HMMFILE *hfp) except *

Expand Down
4 changes: 2 additions & 2 deletions pyhmmer/plan7.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -3442,10 +3442,10 @@ cdef class HMMFile:
self._name = os.fsdecode(fspath)
if db:
function = "p7_hmmfile_OpenE"
status = libhmmer.p7_hmmfile.p7_hmmfile_OpenE(fspath, NULL, &self._hfp, errbuf)
status = libhmmer.p7_hmmfile.p7_hmmfile_Open(fspath, NULL, &self._hfp, errbuf)
else:
function = "p7_hmmfile_OpenENoDB"
status = libhmmer.p7_hmmfile.p7_hmmfile_OpenENoDB(fspath, NULL, &self._hfp, errbuf)
status = libhmmer.p7_hmmfile.p7_hmmfile_OpenNoDB(fspath, NULL, &self._hfp, errbuf)
except TypeError:
self._hfp = HMMFile._open_fileobj(file)
status = libeasel.eslOK
Expand Down

0 comments on commit 0f92f32

Please sign in to comment.