rickhelmus / patRoon

Workflow solutions for mass-spectrometry based non-target analysis.
https://rickhelmus.github.io/patRoon/
GNU General Public License v3.0
58 stars 17 forks source link

Installation failure #76

Closed Emma-Palm closed 1 year ago

Emma-Palm commented 1 year ago

Hi,

I am trying to install patRoon on my Windows computer and encountered installation failures for the two library files PubChem Lite and CompTox when running the automatic installation. The problem seems to be in the download.file function based on the error messages pasted below.

trying URL 'https://zenodo.org/record/6503754/files/PubChemLite_exposomics_20220429.csv' Content type 'text/plain; charset=utf-8' length 194536409 bytes (185.5 MB) downloaded 73.1 MB

Error in download.file(url, dest, mode = "wb") : download from 'https://zenodo.org/record/6503754/files/PubChemLite_exposomics_20220429.csv' failed In addition: Warning messages: 1: In download.file(url, dest, mode = "wb") : downloaded length 76626898 != reported length 194536409 2: In download.file(url, dest, mode = "wb") :

trying URL 'https://zenodo.org/record/3472781/files/CompTox_07March19_WWMetaData.csv' Content type 'text/plain; charset=utf-8' length 323671657 bytes (308.7 MB) downloaded 82.2 MB

Error in download.file(url, dest, mode = "wb") : download from 'https://zenodo.org/record/3472781/files/CompTox_07March19_WWMetaData.csv' failed In addition: Warning messages: 1: In fun(libname, pkgname) : mzR has been built against a different Rcpp version (1.0.9) than is installed on your system (1.0.10). This might lead to errors when loading mzR. If you encounter such issues, please send a report, including the output of sessionInfo() to the Bioc support forum at https://support.bioconductor.org/. For details see also https://github.com/sneumann/mzR/wiki/mzR-Rcpp-compiler-linker-issue. 2: replacing previous import ‘jsonlite::validate’ by ‘shiny::validate’ when loading ‘KPIC’ 3: In download.file(url, dest, mode = "wb") : downloaded length 86211541 != reported length 323671657 4: In download.file(url, dest, mode = "wb") :

I have the same problem on two separate computers with different versions of R but this is one of them: R version 4.2.1 (2022-06-23 ucrt) Platform: x86_64-w64-mingw32/x64 (64-bit) Running under: Windows 10 x64 (build 19044)

rickhelmus commented 1 year ago

Hi Emma,

Thanks for your report!

I just tested it myself and can reproduce the problem. After a bit of Googling, this seems to be a common problem with the download.file() function that is used by the script: https://stackoverflow.com/a/68944877

On my current system the timeout is set to 60 seconds, which for these large files is probably too short. Increasing the timeout as is done in the linked stackoverflow post seems to fix it for me.

options(timeout = 300)

I'll see if I can override the timeout in the installation script so this won't need to be done manually.

Thanks, Rick

rickhelmus commented 1 year ago

Closing this as it should be fixed now. Feel free to re-open if not! :-)