Error when downloading ERA5/ERA5-land using CDSAPI.retrieve: 'Overload' object has no attribute 'timeout'

Hi Forum,

I am using a R script that calls cdsapi through a python interface (reticulate package). The script is a loop that sends single requests in line as I need to cover a large temporal and spatial extent.

Some months ago this script worked well and I was able to download the data without problems. However I am currently getting this error:

 Error in py_call_impl(callable, dots$args, dots$keywords) :  Exception: an internal error occurred processing your request. 'Overload' object has no attribute 'timeout'. 

Sometimes it downloads the first request of the loop, but then I get this message.

I haven't found any information about this issue and about the 'Overload' object. Regarding the timeout attribute I included it to de client.

Any help is appreciated

Here is my code:

rm(list=ls())
Sys.setenv(LANG = "en")
library(reticulate)
library(tidyverse)
use_condaenv("Anaconda3",required = TRUE)
cdsapi<-import("cdsapi")

t<-as.integer(600)
server = cdsapi$Client(timeout=t,quiet=FALSE,debug=TRUE)


a<-list.files("D:/alonso/stage_1/predictors/ERA5/download_data",full.names=TRUE)
path<-"D:/alonso/stage_1/predictors/ERA5/download_data/"
var<-c("10m_u_component_of_wind","10m_v_component_of_wind","2m_temperature","skin_temperature","soil_temperature_level_1","surface_pressure",
"total_precipitation")

y<-2010
m<-seq(1,12,1)  
for(i in seq_along(y)){
  for(i2 in seq_along(m)){
    for(i3 in seq_along(var)){
      b<-paste(path,"era5_",var[i3],y[i],m[i2],".nc",sep="",collapse="")
      if(any(grepl(b,a)==TRUE)){
        next}
      print(b)
      querry<-r_to_py(list(
        #product_type="reanalysis",
        format="netcdf",
        variable=var[i3],
        year=as.character(y[i]),
        month=str_pad(m[i2],2,"left","0"),
        day=str_pad(1:31,2,"left","0"),
        time=str_c(0:23,"00",sep=":")%>%str_pad(5,"left","0"),
        area=c( 72, -30, 33,35)))
      server$retrieve("reanalysis-era5-land",querry,b)
    }
  }
}


I am getting this error message:

DEBUG REPLY {'state': 'failed', 'request_id': 'b17513f0-e26a-4855-acdc-0e20e2a5dca7', 'error': {'message': 'an internal error occurred processing your request', 'url': 'http://copernicus-climate.eu/exc/exception', 'reason': "'Overload' object has no attribute 'timeout'", 'context': {'traceback': 'Traceback (most recent call last):\n  File "/opt/cdstoolbox/cdscompute/cdscompute/cdshandlers/services/handler.py", line 51, in handle_request\n    timeout = proc.timeout\nAttributeError: \'Overload\' object has no attribute \'timeout\'\n'}, 'permanent': True, 'who': 'server'}, 'sent_to_rmq_at': '2022-02-24T14:48:56.631Z', 'specific_metadata_json': {'top_request_origin': 'api'}}
INFO Request is failed
ERROR Message: an internal error occurred processing your request
ERROR Reason:  'Overload' object has no attribute 'timeout'
ERROR   Traceback (most recent call last):
ERROR     File "/opt/cdstoolbox/cdscompute/cdscompute/cdshandlers/services/handler.py", line 51, in handle_request
ERROR       timeout = proc.timeout
ERROR   AttributeError: 'Overload' object has no attribute 'timeout'





Hi,

there was a temporary issue in the system but now it is fixed.

Please try to run the request again

Thanks

Michela

Thank you Michaela! Its working now