luna icon indicating copy to clipboard operation
luna copied to clipboard

Error downloading AVHRR data

Open StefanoMezzini opened this issue 1 year ago • 0 comments

Hi,

I just installed luna to download AVHRR data, and I keep getting the following error:

> library('luna') # for avhrr, modis, sentinel, and landsat data
> 
> getAVHRR(start_date = '1981-06-24',
+          end_date = '1981-06-24',
+          path = 'data/ndvi-rasters/avhrr',
+          overwrite = FALSE,
+          update = FALSE)
Creating index of available AVHRR files on 2023-07-02 
Downloading AVHRR tile for 1981-06-24 
Error in match.arg(method, c("auto", "internal", "wininet", "libcurl",  : 
  'arg' must be NULL or a character vector

The error occurs with both the GitHub version (remotes::install_github("rspatial/luna")) and the version from install.packages("luna", repos = "https://rspatial.r-universe.dev"). I believe it's because download.file doesn't have a default method and getAVHRR can't pass the method argument since the download.file call is missing a ....

Cheers, Stefano

StefanoMezzini avatar Jul 02 '23 07:07 StefanoMezzini