cdsapi icon indicating copy to clipboard operation
cdsapi copied to clipboard

Exception: Missing/incomplete configuration

Open saptisunil opened this issue 4 years ago • 2 comments

Exception Traceback (most recent call last) in 1 import cdsapi 2 ----> 3 c = cdsapi.Client() 4 5 c.retrieve(

~\anaconda3\lib\site-packages\cdsapi\api.py in init(self, url, key, quiet, debug, verify, timeout, progress, full_stack, delete, retry_max, sleep_max, wait_until_complete, info_callback, warning_callback, error_callback, debug_callback, metadata, forget, session) 299 300 if url is None or key is None or key is None: --> 301 raise Exception("Missing/incomplete configuration file: %s" % (dotrc)) 302 303 self.url = url

Exception: Missing/incomplete configuration file: C:\Users\HP/.cdsapirc

saptisunil avatar Feb 19 '21 16:02 saptisunil

Can anyone help me with this issue???

saptisunil avatar Feb 19 '21 16:02 saptisunil

@saptisunil It looks like you need to add url: https://cds.climate.copernicus.eu/api/v2 to your .cdsapirc file.

Here is how to set it up if this file doesn't exist. https://cds.climate.copernicus.eu/api-how-to

lgloege avatar Mar 27 '21 04:03 lgloege

Hi, Thanks providing the solution @lgloege Eddy

EddyCMWF avatar Feb 28 '23 10:02 EddyCMWF

@lgloege it doesn't work for me. the .cdsapirc is complete.

MeHashemi avatar May 17 '23 05:05 MeHashemi

@lgloege it doesn't work for me. the .cdsapirc is complete.

Just put the two lines of text from the .cdsapirc file arguments in the cdsapi.Client(url = "...", key = "...") function instead.

zachHTF avatar Jun 15 '23 19:06 zachHTF