Giter VIP home page Giter VIP logo

bioservices.jl's Introduction

Bio

Latest release MIT license Pkg Status

This package has been depreceated. Full details are available here. You might still download and use this package, as we don't want old scripts to break. However going forward, know that this repository is archived and read only, no further updates or fixes will be committed. You should use the packages that replace Bio.jl - a list is available here.

bioservices.jl's People

Contributors

aguang avatar bicycle1885 avatar bioturbonick avatar ibacher avatar kescobo avatar mcmcgrath13 avatar mimame avatar mirestrepo avatar quinnj avatar yuifu avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bioservices.jl's Issues

recommended limits on term length?

Thanks for this awesome package!

Suppose I have 50k IDs to check, how many should I send at a time for queries like:

res = esearch(db="gene",term="ENSG00000000003 OR ENSG00000000005 OR ENSG00000000419", retmode="xml")

Efetch

The efetch function is giving me errors when I run the following command:
where request_str is a array of pmids.

EUtils.efetch(db = "pubmed", tool = "BioJulia", retmode = "xml", rettype = "null", id = request_str)

Expected Behavior

The function should return formatted data records for a the list of pmids.

Current Behavior

This is the output that I get when I try to run efetch.

.jl:613
caused by [exception 5]
error compiling #getconnection#11: error compiling #sslconnection#18: error compiling global_sslconfig: error compiling #SSLConfig#46: could not load library "C:\Users\Thor.julia\packages\MbedTLS\a1JFn\deps\usr\bin\libmbedtls.dll"
The specified procedure could not be found.

Stacktrace:
[1] #request#1(::Nothing, ::Type, ::Int64, ::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ConnectionRequest.jl:41
[2] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[3] #request#1(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::Vararg{Any,N} where N) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ExceptionRequest.jl:19
[4] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[5] (::getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)})(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::getfield(Base, Symbol("##50#52")){getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)}}, ::Type, ::Vararg{Any,N} where N) at .\error.jl:249
[6] #request#1(::VersionNumber, ::String, ::Nothing, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[7] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[8] #request#1(::Int64, ::Bool, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\RedirectRequest.jl:24
[9] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[10] #request#5(::Array{Pair{SubString{String},SubString{String}},1}, ::String, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::String, ::String, ::Array{Pair{SubString{String},SubString{String}},1}, ::Array{UInt8,1}) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\HTTP.jl:308
[11] #request at .\none:0 [inlined] (repeats 2 times)
[12] #efetch#5 at C:\Users\Thor.julia\packages\BioServices\KPZxN\src\eutils.jl:126 [inlined]
[13] #efetch at .\none:0 [inlined] (repeats 2 times)
[14] get_pubmed_efetch_as_xml(::Array{Any,1}) at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:482
[15] main() at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:577
[16] top-level scope at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:613
[17] include at .\boot.jl:328 [inlined]
[18] include_relative(::Module, ::String) at .\loading.jl:1094
[19] include(::Module, ::String) at .\Base.jl:31
[20] exec_options(::Base.JLOptions) at .\client.jl:295
[21] _start() at .\client.jl:464
caused by [exception 4]
error compiling #sslconnection#18: error compiling global_sslconfig: error compiling #SSLConfig#46: could not load library "C:\Users\Thor.julia\packages\MbedTLS\a1JFn\deps\usr\bin\libmbedtls.dll"
The specified procedure could not be found.

Stacktrace:
[1] #request#1(::Nothing, ::Type, ::Int64, ::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ConnectionRequest.jl:41
[2] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[3] #request#1(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::Vararg{Any,N} where N) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ExceptionRequest.jl:19
[4] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[5] (::getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)})(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::getfield(Base, Symbol("##50#52")){getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)}}, ::Type, ::Vararg{Any,N} where N) at .\error.jl:249
[6] #request#1(::VersionNumber, ::String, ::Nothing, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[7] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[8] #request#1(::Int64, ::Bool, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\RedirectRequest.jl:24
[9] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[10] #request#5(::Array{Pair{SubString{String},SubString{String}},1}, ::String, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::String, ::String, ::Array{Pair{SubString{String},SubString{String}},1}, ::Array{UInt8,1}) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\HTTP.jl:308
[11] #request at .\none:0 [inlined] (repeats 2 times)
[12] #efetch#5 at C:\Users\Thor.julia\packages\BioServices\KPZxN\src\eutils.jl:126 [inlined]
[13] #efetch at .\none:0 [inlined] (repeats 2 times)
[14] get_pubmed_efetch_as_xml(::Array{Any,1}) at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:482
[15] main() at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:577
[16] top-level scope at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:613
[17] include at .\boot.jl:328 [inlined]
[18] include_relative(::Module, ::String) at .\loading.jl:1094
[19] include(::Module, ::String) at .\Base.jl:31
[20] exec_options(::Base.JLOptions) at .\client.jl:295
[21] _start() at .\client.jl:464
caused by [exception 3]
error compiling global_sslconfig: error compiling #SSLConfig#46: could not load library "C:\Users\Thor.julia\packages\MbedTLS\a1JFn\deps\usr\bin\libmbedtls.dll"
The specified procedure could not be found.

Stacktrace:
[1] #request#1(::Nothing, ::Type, ::Int64, ::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ConnectionRequest.jl:41
[2] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[3] #request#1(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::Vararg{Any,N} where N) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ExceptionRequest.jl:19
[4] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[5] (::getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)})(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::getfield(Base, Symbol("##50#52")){getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)}}, ::Type, ::Vararg{Any,N} where N) at .\error.jl:249
[6] #request#1(::VersionNumber, ::String, ::Nothing, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[7] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[8] #request#1(::Int64, ::Bool, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\RedirectRequest.jl:24
[9] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[10] #request#5(::Array{Pair{SubString{String},SubString{String}},1}, ::String, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::String, ::String, ::Array{Pair{SubString{String},SubString{String}},1}, ::Array{UInt8,1}) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\HTTP.jl:308
[11] #request at .\none:0 [inlined] (repeats 2 times)
[12] #efetch#5 at C:\Users\Thor.julia\packages\BioServices\KPZxN\src\eutils.jl:126 [inlined]
[13] #efetch at .\none:0 [inlined] (repeats 2 times)
[14] get_pubmed_efetch_as_xml(::Array{Any,1}) at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:482
[15] main() at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:577
[16] top-level scope at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:613
[17] include at .\boot.jl:328 [inlined]
[18] include_relative(::Module, ::String) at .\loading.jl:1094
[19] include(::Module, ::String) at .\Base.jl:31
[20] exec_options(::Base.JLOptions) at .\client.jl:295
[21] _start() at .\client.jl:464
caused by [exception 2]
error compiling #SSLConfig#46: could not load library "C:\Users\Thor.julia\packages\MbedTLS\a1JFn\deps\usr\bin\libmbedtls.dll"
The specified procedure could not be found.

Stacktrace:
[1] #request#1(::Nothing, ::Type, ::Int64, ::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ConnectionRequest.jl:41
[2] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[3] #request#1(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::Vararg{Any,N} where N) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ExceptionRequest.jl:19
[4] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[5] (::getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)})(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::getfield(Base, Symbol("##50#52")){getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)}}, ::Type, ::Vararg{Any,N} where N) at .\error.jl:249
[6] #request#1(::VersionNumber, ::String, ::Nothing, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[7] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[8] #request#1(::Int64, ::Bool, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\RedirectRequest.jl:24
[9] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[10] #request#5(::Array{Pair{SubString{String},SubString{String}},1}, ::String, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::String, ::String, ::Array{Pair{SubString{String},SubString{String}},1}, ::Array{UInt8,1}) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\HTTP.jl:308
[11] #request at .\none:0 [inlined] (repeats 2 times)
[12] #efetch#5 at C:\Users\Thor.julia\packages\BioServices\KPZxN\src\eutils.jl:126 [inlined]
[13] #efetch at .\none:0 [inlined] (repeats 2 times)
[14] get_pubmed_efetch_as_xml(::Array{Any,1}) at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:482
[15] main() at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:577
[16] top-level scope at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:613
[17] include at .\boot.jl:328 [inlined]
[18] include_relative(::Module, ::String) at .\loading.jl:1094
[19] include(::Module, ::String) at .\Base.jl:31
[20] exec_options(::Base.JLOptions) at .\client.jl:295
[21] _start() at .\client.jl:464
caused by [exception 1]
could not load library "C:\Users\Thor.julia\packages\MbedTLS\a1JFn\deps\usr\bin\libmbedtls.dll"
The specified procedure could not be found.

Stacktrace:
[1] #request#1(::Nothing, ::Type, ::Int64, ::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ConnectionRequest.jl:41
[2] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ConnectionPoolLayer{StreamLayer{Union{}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[3] #request#1(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::Vararg{Any,N} where N) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\ExceptionRequest.jl:19
[4] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:iofunction,),Tuple{Nothing}}, ::typeof(HTTP.request), ::Type{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}, ::HTTP.URIs.URI, ::HTTP.Messages.Request, ::String) at .\none:0
[5] (::getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)})(::Base.Iterators.Pairs{Symbol,Nothing,Tuple{Symbol},NamedTuple{(:iofunction,),Tuple{Nothing}}}, ::getfield(Base, Symbol("##50#52")){getfield(Base, Symbol("###50#51#53")){ExponentialBackOff,getfield(HTTP.RetryRequest, Symbol("##2#3")){Bool,HTTP.Messages.Request},typeof(HTTP.request)}}, ::Type, ::Vararg{Any,N} where N) at .\error.jl:249
[6] #request#1(::VersionNumber, ::String, ::Nothing, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[7] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[8] #request#1(::Int64, ::Bool, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\RedirectRequest.jl:24
[9] (::getfield(HTTP, Symbol("#kw##request")))(::NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}, ::typeof(HTTP.request), ::Type{RedirectLayer{MessageLayer{RetryLayer{ExceptionLayer{ConnectionPoolLayer{StreamLayer{Union{}}}}}}}}, ::String, ::HTTP.URIs.URI, ::Array{Pair{SubString{String},SubString{String}},1}, ::String) at .\none:0
[10] #request#5(::Array{Pair{SubString{String},SubString{String}},1}, ::String, ::Nothing, ::Base.Iterators.Pairs{Symbol,Bool,Tuple{Symbol},NamedTuple{(:retry_non_idempotent,),Tuple{Bool}}}, ::typeof(HTTP.request), ::String, ::String, ::Array{Pair{SubString{String},SubString{String}},1}, ::Array{UInt8,1}) at C:\Users\Thor.julia\packages\HTTP\6Smhf\src\HTTP.jl:308
[11] #request at .\none:0 [inlined] (repeats 2 times)
[12] #efetch#5 at C:\Users\Thor.julia\packages\BioServices\KPZxN\src\eutils.jl:126 [inlined]
[13] #efetch at .\none:0 [inlined] (repeats 2 times)
[14] get_pubmed_efetch_as_xml(::Array{Any,1}) at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:482
[15] main() at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:577
[16] top-level scope at C:\Users\Thor\Documents\Machine Learning\Work\collect_data.jl:613
[17] include at .\boot.jl:328 [inlined]
[18] include_relative(::Module, ::String) at .\loading.jl:1094
[19] include(::Module, ::String) at .\Base.jl:31
[20] exec_options(::Base.JLOptions) at .\client.jl:295
[21] _start() at .\client.jl:464

Your Environment

  • Package Version used: 0.3.2
  • Julia Version used: 1.2
  • Operating System and version (desktop or mobile): Windows 10

"CSV" => v"0.5.14"
"TextAnalysis" => v"0.6.0"
"BioMedQuery" => v"0.6.4"
"Atom" => v"0.10.1"
"Juno" => v"0.7.2"
"Conda" => v"1.3.0"
"HTTP" => v"0.8.7"
"DecFP" => v"0.4.8"
"LinearAlgebra" => nothing
"Missings" => v"0.4.3"
"ScikitLearn" => v"0.5.1"
"BioServices" => v"0.3.2"
"StatsBase" => v"0.32.0"
"VariantVisualization" => v"0.4.0"
"Tables" => v"0.2.11"
"EzXML" => v"0.9.4"
"MbedTLS" => v"0.7.0"
"Languages" => v"0.4.2"
"DataFrames" => v"0.19.4"
"Printf" => nothing
"MySQL" => v"0.7.1"
"LightXML" => v"0.8.1"

Better handling of HTTP errors in EUtils

Expected Behavior

Handle EUtils HTTP errors gracefully

Current Behavior

Some HTTP errors throw rather cryptic errors. For instance if more NCBI's API frequency is exceeded (3 calls/seconds), we get an error

Got an exception of type HTTP.IOExtras.IOError outside of a @test
  IOError(EOFError() during request(https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esummary...

Possible Solution / Implementation

Try/Catch, if error is of the right type, sleep(0.3) try again. We need to investigate if the HTTP error is consistent in this case
Alternatively, we could keep a global representing time since last call?

Steps to Reproduce (for bugs)

If the sleep(0.3) lines are taken out of tests, then they intermittently fail

Change functions to use HTTP.jl package instead of deprecated Requests and HttpCommon.

Expected Behavior

HTTP requests should be performed using the package HTTP.jl.

Current Behavior

Currently, BioServices.jl uses Requests and HttpCommon which are deprecated.

Implementation

Example of updated function:

import HTTP

function einfo(ctx::Associative=empty_context(); params...)
    params = process_parameters(params, ctx)
    return HTTP.request("GET", string(baseURL, "einfo.fcgi"), query=params)
end

Usage:

using BioServices.EUtils

res = einfo(db = "pubmed")

write("result.xml", res.body)

Error 414 Request-URI Too Large

Expected Behavior

When using eFetch (via BioMedQuery), should return results. This is for a simple query (e.g. term="asthma"[mh:noexp]), which is not very long.

Current Behavior

HTTP returns a 414 error saying the URI was too long. With postman, this did work.

Possible Solution / Implementation

Steps to Reproduce (for bugs)

BioMedQuery.Processes.pubmed_search_and_parse("", """("asthma"[mh:noexp])""", 999999999999)

Which calls:

using XMLDict
using BioServices.EUtils

rs = 0
retmax = 10000
term = """"asthma"[mh:noexp]"""
email = ""

search_response = esearch(db = "pubmed", term = search_term,
        retstart = rs, retmax = retmax, tool = "BioJulia",
        email = email)

        # if verbose
        #     xdoc = parse_string(esearch_response)
        #     save_file(xdoc, "./esearch.xml")
        # end

        #convert xml to dictionary
        esearch_dict = parse_xml(String(esearch_response.body))

        if !haskey(esearch_dict, "IdList")
            println("Error with esearch_dict:")
            println(esearch_dict)
            error("Response esearch_dict does not contain IdList")
        end

        println("------EFetch--------")

        #get the list of ids and perfom a fetch
        ids = [parse(Int64, id_node) for id_node in esearch_dict["IdList"]["Id"]]

        efetch_response = efetch(db = "pubmed", tool = "BioJulia", retmode = "xml", rettype = "null", id = ids)

Context

Trying to get articles related to a mesh term for further processing. This is the first step.

Your Environment

TagBot trigger issue

This issue is used to trigger TagBot; feel free to unsubscribe.

If you haven't already, you should update your TagBot.yml to include issue comment triggers.
Please see this post on Discourse for instructions and more details.

If you'd like for me to do this for you, comment TagBot fix on this issue.
I'll open a PR within a few hours, please be patient!

Update CI and docs to github actions

Given that #31 still has not been resolved due to docs not updating, and that issue has been around for over a year, I think it would be worth updating CI and deployment. @jakobnissen Can you get me admin rights on this repo and I'll go ahead and make the switch?

Replace EzXML with LightXML

@bicycle1885 EzXML has not been building in Linux since Julia 0.6.3 and the issue has not been addressed. The xml functionality needed for EUtils is minimal. Do you oppose if we switch BioServices to use LightXML? Or are you actively working on EzXML?

Add ULMS token to run tests

See here: #36 (comment)

One last thing is that someone should probably get an account with UMLs and put a token as a secret for UMLS tests to run. If no credentials are found those tests are skipped, which is fine in the short term, but may be nice to have them run...

ERROR: type Response has no field data

This template is rather extensive. Fill out all that you can, if are a new contributor or you're unsure about any section, leave it unchanged and a reviewer will help you ๐Ÿ˜„. This template is simply a tool to help everyone remember the BioJulia guidelines, if you feel anything in this template is not relevant, simply delete it.

I am trying to use EUtils to query NCBI's Entrez databases. When I run the example in the documentation, it does not produce the expected behavior:

res = efetch(db="nuccore", id="NM_001126.3", retmode="xml")
doc = parsexml(res.data)

Expected Behavior

Expected behavior is for parsexml to work and provide me with an object I can extract specific fields from.

Current Behavior

Instead, I get:

julia> doc = parsexml(res.data)
ERROR: type Response has no field data
Stacktrace:
 [1] getproperty(::Any, ::Symbol) at ./sysimg.jl:18
 [2] top-level scope at none:0

Steps to Reproduce (for bugs)

res = efetch(db="nuccore", id="NM_001126.3", retmode="xml")
doc = parsexml(res.data)

Context

I want to be able to extract a specific field from querying an Entrez database (in my case IDs from the IdList of an SRA query).

Your Environment

  • Package Version used:
    Status
  [a0d4ced5] + BioServices v0.3.2
  [8f5d6c58] + EzXML v1.0.0
  [ddb6d928] + YAML v0.3.2
  • Julia Version used:
julia> versioninfo()
Julia Version 1.1.0
Commit 80516ca202 (2019-01-21 21:24 UTC)
Platform Info:
  OS: macOS (x86_64-apple-darwin14.5.0)
  CPU: Intel(R) Core(TM) i7-7820HQ CPU @ 2.90GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-6.0.1 (ORCJIT, skylake)
  • Operating System and version (desktop or mobile): macOS Mojave

Is this the package to use for eutils after restructuring

I am really excited about the new modular approach. I'd like to try the Entrez Utilities part of this. Since this code is still part of Bio.jl and this new repo - how I should be using it.
Is is okay to do Pkg.clone() for this repo? Is this the place where new PR and issues should be open? Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.