Open tghazanchyan opened 1 month ago
Please show the code that fails as well as your sessionInfo()
I believe OP is talking about this:
.downloadData <- function(file, tax_id, NCBIFilesDir, rebuildCache, verbose)
{
if (verbose)
message("getting data for ", names(file))
## NCBI connection
if (is.null(NCBIFilesDir)) {
NCBIcon <- dbConnect(SQLite(), dbname = tempfile())
tmp <- tempfile()
} else {
NCBIcon <- dbConnect(SQLite(),
dbname = file.path(NCBIFilesDir, "NCBI.sqlite"))
tmp <- file.path(NCBIFilesDir, names(file))
}
tableName <- sub(".gz","",names(file))
## download
if (rebuildCache) {
if(names(file) == "gene2unigene"){
url <- paste0("ftp://ftp.ncbi.nlm.nih.gov/gene/DATA/ARCHIVE/", names(file))
}else{
url <- paste0("ftp://ftp.ncbi.nlm.nih.gov/gene/DATA/", names(file))
}
Thanks @jmacdon ! Yes, I was referring to the hardcoded FTP links. It would be great to have a parameter that allows for selecting between FTP and HTTP.
In certain environments, access to external resources via the insecure FTP protocol is entirely blocked. Could you kindly provide an option to switch to the HTTP protocol for downloading data from NCBI? NCBI offers symmetrical access to the same data over both FTP and HTTP.