Open stolltho opened 4 years ago
Hi @stolltho ! Thanks for your patience - I've been off for the last while and am returning to work now. Can you check your /databases/hmdb_source folder if there is a zip file in there of approx. 700 MB? Then I can narrow down if it is due to the download failing or being blocked or something :)
hi Joanna. HMDB.zip file is just 1KB and can't be opened. cheers, Thomas
On Sat, May 23, 2020 at 7:52 AM joannawolthuis notifications@github.com wrote:
Hi @stolltho https://github.com/stolltho ! Thanks for your patience - I've been off for the last while and am returning to work now. Can you check your /databases/hmdb_source folder if there is a zip file in there of approx. 700 MB? Then I can narrow down if it is due to the download failing or being blocked or something :)
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/joannawolthuis/MetaboShiny/issues/44#issuecomment-632922607, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD2PB34RDLF2MSJHBOGO6EDRS3X2NANCNFSM4M2BAVIQ .
Hi! That is strange, it means the download failed.. Did you try multiple times? And are you working from the docker image or native R (in windows?)
Hi Joanna
I am using R. I tried to build several DB several times, w/o success. I am getting all sorts of error messages:
HMDB
[1] TRUE
Warning: The 'plotly_click' event tied a source ID of 'A' is not registered. In order to obtain this event data, please add event_register(p, 'plotly_click')
to the plot (p
) that you wish to obtain event data from.
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 162 100 162 0 0 162 0 0:00:01 --:--:-- 0:00:01 272
Warning in utils::unzip(zip.file, exdir = base.loc) :
error 1 in extracting from zip file
Warning in file(con, "r") :
cannot open file 'C:\Users\stoll\Documents\MetaboShiny\databases/hmdb_source/hmdb_metabolites.xml': No such file or directory
Warning: Error in file: cannot open the connection
80: file
79: readLines
78: build.HMDB
77: MetaDBparse::buildBaseDB
73: observeEventHandler [reactive/metabolitedbs.R#333]
2: shiny::runApp
1: start.metshi
[1] "Closing MetaboShiny ~ヾ(^∇^)"
MassBank
[1] TRUE
Warning: replacing previous import ‘XML::xml’ by ‘rvest::xml’ when loading ‘MetaDBparse’
Warning: The 'plotly_click' event tied a source ID of 'A' is not registered. In order to obtain this event data, please add event_register(p, 'plotly_click')
to the plot (p
) that you wish to obtain event data from.
Warning: Error in
83:
[1] "Closing MetaboShiny ~ヾ(^∇^)"
ChEBI
Error : .onLoad failed in loadNamespace() for 'rcdklibs', details:
call: .jinit(classpath = c(jars))
error: Cannot create Java virtual machine (-6)
KEGG
[1] TRUE
Warning: The 'plotly_click' event tied a source ID of 'A' is not registered. In order to obtain this event data, please add event_register(p, 'plotly_click')
to the plot (p
) that you wish to obtain event data from.
|++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=10s
Warning: Error in as.Date.default: do not know how to convert 'date' to class “Date”
81: stop
80: as.Date.default
78: build.KEGG
77: MetaDBparse::buildBaseDB
73: observeEventHandler [reactive/metabolitedbs.R#333]
2: shiny::runApp
1: start.metshi
[1] "Closing MetaboShiny ~ヾ(^∇^)"
From: joannawolthuis notifications@github.com Sent: Saturday, 23 May 2020 9:23 PM To: joannawolthuis/MetaboShiny MetaboShiny@noreply.github.com Cc: stolltho stolltho@gmail.com; Mention mention@noreply.github.com Subject: Re: [joannawolthuis/MetaboShiny] Building database failed (#44)
Hi! That is strange, it means the download failed.. Did you try multiple times? And are you working from the docker image or native R (in windows?)
— You are receiving this because you were mentioned. Reply to this email directly, https://github.com/joannawolthuis/MetaboShiny/issues/44#issuecomment-633030574 view it on GitHub, or https://github.com/notifications/unsubscribe-auth/AD2PB32ARH4LGZ3LM4HJUSTRS6WY7ANCNFSM4M2BAVIQ unsubscribe. https://github.com/notifications/beacon/AD2PB37KFA4VC3BZ647FHT3RS6WY7A5CNFSM4M2BAVI2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEW5UPLQ.gif
Hi there! Thanks for the log. It seems that some updates are needed on the database parsing area, which I'm working on now (on a Windows machine) :) Java in R seems to be really tough and requires seperate (non-MetaboShiny) debugging - I think if you go to the repo/help page for rcdklibs they should have something to help you set up. It's very system specific so I cannot help you on the java virtual machine error, unfortunately :( The rest I'm sure I can fix - except that I don't understand why HMDB is not downloading. Let's retry that once I push the next fix for the other databases.
Hi! I pushed an update that should fix all the bugs that I could reproduce (the ones you posted except the HMDB download failing), can you take a look? :)
Whoops, what I meant is please update the MetaDBparse package through
devtools::install_github("joannawolthuis/MetaDBparse")
I found the HMDB issue. The zip file is actually an html file because the download url changed:
<html>
<head><title>301 Moved Permanently</title></head>
<body>
<center><h1>301 Moved Permanently</h1></center>
<hr><center>nginx</center>
</body>
</html>
You need to validate that you got a good response code when downloading the database to prevent this. However, I did a search and couldn't find any code specifying the url. Is this done in one of the dependencies?
I manage to build the HMDB database by changing the build.HMDB function to use wget insted of default utils::download.file
download method.
@stolltho and @jrm5100 you can try this temporary fix:
library(MetaDBparse)
trace(build.HMDB, edit = T)
and change line 12 to:
utils::download.file(file.url, zip.file, mode = "wb", cacheOK = TRUE, method = "wget")
then load MetaboShiny and try to build the HMDB database.
I'm using RStudio on Linux dont know if this method is valid for other OS
Hi all! Last time I checked indeed it was not the URL but something else. @RuiNascimento thanks for diving in and finding a fix! I will boot up my Windows PC and check if this works there too, my current is a Mac so I can test on all. :) @jrm5100 I will see if I can add in a response checker ASAP, good point!
Oh and yes the database building code is in a dependency (MetaDBparse) but that is also our package. I'm currently leaving issues for it here, maybe in the future I'll ask people to submit issues at joannawolthuis/MetaDBparse.
It seems I can't reproduce this - but nevertheless I tried setting method = "auto" in all download.file calls in the most recent MetaDBparse version :) If any of you could try updating to see if this works I'd be super grateful!
@joannawolthuis (At least on linux) Building the HMDB database works with the new commits on MetaDBparse
Hi there. Building a database returns the following error. Any idea what the problem is? Cheers, Thomas
[1] TRUE Warning: replacing previous import ‘XML::xml’ by ‘rvest::xml’ when loading ‘MetaDBparse’ Warning: The 'plotly_click' event tied a source ID of 'A' is not registered. In order to obtain this event data, please add
event_register(p, 'plotly_click')
to the plot (p
) that you wish to obtain event data from. % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 162 100 162 0 0 162 0 0:00:01 --:--:-- 0:00:01 252 Warning in utils::unzip(zip.file, exdir = base.loc) : error 1 in extracting from zip file Warning in file(con, "r") : cannot open file 'C:\Users\stoll\Documents\MetaboShiny\databases/hmdb_source/hmdb_metabolites.xml': No such file or directory Warning: Error in file: cannot open the connection 80: file 79: readLines 78: build.HMDB 77: MetaDBparse::buildBaseDB 73: observeEventHandler [reactive/metabolitedbs.R#333] 2: shiny::runApp 1: start.metshi [1] "Closing MetaboShiny ~ヾ(^∇^)"