zoon icon indicating copy to clipboard operation
zoon copied to clipboard

SSL and-or Curl related errors in Windows package

Open phjacobs opened this issue 4 years ago • 1 comments

Hello Tom et al.! I reached out to Nick about this and he suggested GitHub would be the better place to mention/ask about it.

The current version of zoon (0.65) won't work on Windows due to SSL/Curl related errors. You can see this in the check results on CRAN: https://cran.r-project.org/web/checks/check_results_zoon.html

Here is an actual example of the error "in the wild" from something I am working on:

Error in function (type, msg, asError = TRUE) : error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version Traceback:

  1. workflow(occurrence = LocalOccurrenceData(filename = "occurrence.csv", . occurrenceType = "presence/absence", columns = c(long = "Longitude", . lat = "Latitude", value = "presence")), covariate = LocalRaster("raster"), . process = Chain(Bootstrap, Crossvalidate(k = 5)), model = RandomForest, . output = Chain(PerformanceMeasures, VariableImportance, PrintMap(plot = TRUE)))
  2. LapplyGetModule(occurrence.module, forceReproducible, e)
  3. lapply(modules, function(x) { . GotModule <- GetModule(as.character(x$module), forceReproducible, . environment) . res <- c(x, func = GotModule, version = attr(GotModule, "version")) . return(res) . })
  4. FUN(X[[i]], ...)
  5. GetModule(as.character(x$module), forceReproducible, environment)
  6. getURL(zoonURL, ssl.verifypeer = FALSE)
  7. curlPerform(curl = curl, .opts = opts, .encoding = .encoding)
  8. function (type, msg, asError = TRUE) . { . if (!is.character(type)) { . i = match(type, CURLcodeValues) . typeName = if (is.na(i)) . character() . else names(CURLcodeValues)[i] . } . typeName = gsub("^CURLE_", "", typeName) . fun = (if (asError) . stop . else warning) . fun(structure(list(message = msg, call = sys.call()), class = c(typeName, . "GenericCurlError", "error", "condition"))) . }(35L, "error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version", . TRUE)

I am no expert, but I wonder that there is something going on with either the openssl protocol on Windows, and/or whether changes to Github's handling of "raw" files (module list?) are to blame.

I was able to get zoon working on a Ubuntu machine after reinstalling the openssl library on the system AND also installing an archived version of the now deprecated SDMTools package.

phjacobs avatar Feb 23 '21 13:02 phjacobs

Here is a reproducible example

zoonURL <- "https://raw.githubusercontent.com/zoonproject/modules/master/R/Background.R"
RCurl::getURL(zoonURL, ssl.verifypeer = FALSE)

AugustT avatar Feb 23 '21 13:02 AugustT