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

Add support for recent versions of MySQL.jl #74

Open
khughitt opened this issue May 28, 2020 · 5 comments
Open

Add support for recent versions of MySQL.jl #74

khughitt opened this issue May 28, 2020 · 5 comments

Comments

@khughitt
Copy link

Greetings!

I tried using BioMedQuery.jl for the first time today. Installation went smoothly, however, when I attempt to load the package, I run into an error during the pre-compilation step:

julia> using BioMedQuery
[ Info: Precompiling BioMedQuery [e96904bf-1073-5077-9b57-b0ce0ff5555a]
ERROR: LoadError: LoadError: LoadError: UndefVarError: MySQLHandle not defined
Stacktrace:
 [1] top-level scope at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/DBUtils/mysql_db_utils.jl:55
 [2] include(::String) at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/BioMedQuery.jl:4
 [3] top-level scope at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/DBUtils/DBUtils.jl:4
 [4] include(::String) at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/BioMedQuery.jl:4
 [5] top-level scope at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/BioMedQuery.jl:21
 [6] top-level scope at none:2
 [7] eval at ./boot.jl:331 [inlined]
in expression starting at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/DBUtils/mysql_db_utils.jl:55
in expression starting at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/DBUtils/DBUtils.jl:4
in expression starting at /home/keith/.julia/packages/BioMedQuery/Ps32f/src/BioMedQuery.jl:21
ERROR: Failed to precompile BioMedQuery [e96904bf-1073-5077-9b57-b0ce0ff5555a] to /home/keith/.julia/compiled/v1.4/BioMedQuery/I7mWp_L3y04.ji.

Looking at the code for src/DBUtils/mysql_db_utils.jl, I noticed that the function db_query() is attempting to call MySQL.query(), which doesn't appear to be in the current API for MySQL.jl.

I'm guessing that the MySQL.jl API has changed in some recent version, and that BioMedQuery.jl is still referring to the old interface? It's also possible that I am just misunderstanding something..

As a side note, I also noticed that init_mysql_database() function that gets automatically called during the initial attempt to load BioMedQuery.jl attempts to look for the "test" database. Since it is common to remove the test db after installation, it might be good to avoid this, if possible.

Thanks!

System Info

  • Arch Linux 5.6.14 (64-bit)
  • Julia 1.4.2
  • MariaDB 10.4.13

Package versions:

@DilumAluthge
Copy link
Member

Happy to accept pull requests. Unfortunately this package does not have an active maintainer.

@DilumAluthge
Copy link
Member

But if people want to make pull requests, I can merge them.

@timholy
Copy link
Member

timholy commented Nov 9, 2020

This is a cross-post from https://julialang.zulipchat.com/#narrow/stream/232791-sciences/topic/PubChemCrawler/near/216013362. If I were to create a package to search PubChem,

  • is this something I should attempt to integrate with, or is it better to make it standalone? Or base it on some other package?
  • Should I host it at JuliaHealth or elwhere?

@DilumAluthge
Copy link
Member

  • Should I host it at JuliaHealth or elwhere?

I think JuliaHealth would be a great place to host it!

  • is this something I should attempt to integrate with, or is it better to make it standalone? Or base it on some other package?

This question is trickier. The problem is that BioMedQuery.jl currently doesn't have a maintainer. Additionally, I'm not sure if the package is currently functional.

@timholy If you want, you are welcome to take over as maintainer of BioMedQuery.jl. But that might entail some work, e.g. to get CI passing again.

Alternatively, it will probably be easier to develop the PubChem package as a separate package, e.g. something like JuliaHealth/PubChemAPI.jl or something like that.

I would probably recommend the latter approach. Using HTTP.jl and JSON3.jl, it's pretty quick to get a working REST client.

@timholy
Copy link
Member

timholy commented Nov 9, 2020

Sounds good. I'll do the standalone but plan to host it here at JuliaHealth. Thanks for the input!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants