question

Upvotes
Accepted
3 0 1 5

Error code -1|Timed out - We are experiencing this issue on European power spot day ahead auction prices (i.e., ‚EHLDE01“ for Germany and for other markets and hours as well).

The last RICs requested was for Spain I believe, here are the RICs:

OMELES01

OMELES02

OMELES03

OMELES04

OMELES05

OMELES06

api-error.png


The start and end date for this instance was from 18/06/2023 to 03/07/2023.


What is odd in my case is that this code runs this query for multiple countries, always one at a time and for each hour of the day. As I have been checking the countries that get_history() has been successful within each code run and this number varied. Meaning that first I run the code, the error came after 3 countries have been queried (in for loop one country at the time), then the second time 5 countries were successful, then 2, and so on. Error was still the same just different amounts of countries were obtained.

I am using Refinitv.data library in python. I ran rd.open_session() with my Refinitiv Eikon app logged on and then rd.get_history() method as you can see.\


Thank you in advance.

#technologyapipython api
api-error.png (45.9 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
80.3k 259 52 75

@jeremiemae.celajes

It is a Refinitiv Data Library configuration file (refinitiv-data.config.json).

To use it, please refer to the example on GitHub.

You can also try to increase the timeout.

{
    "http": {        
        "request-timeout": 60        
    },
  "logs": {
    "level": "debug",
    "transports": {
      "console": {
        "enabled": false
      },
      "file": {
        "enabled": true,
        "name": "refinitiv-data-lib.log"
      }
    }
  },
  "sessions": {
    "default": "desktop.workspace",
...

Please make sure that you are using the latest version of Refinitiv Data Library (refinitiv-data 1.3.0).

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
80.3k 259 52 75

@jeremiemae.celajes

Thank you for reaching out to us.

I can run it properly.

code_list=["OMELES01","OMELES02","OMELES03","OMELES04","OMELES05","OMELES06"]
temp = rd.get_history(universe=code_list,
                      fields=["TRDPRC_1"], 
                      start="2023-06-18",
                       end="2023-07-03")
temp

1688444210304.png

You may need to enable logging in the API to verify what the problem is.

{
  "logs": {
    "level": "debug",
    "transports": {
      "console": {
        "enabled": false
      },
      "file": {
        "enabled": true,
        "name": "refinitiv-data-lib.log"
      }
    }
  },

1688444460090.png



1688444210304.png (39.1 KiB)
1688444460090.png (16.0 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hi @Jirapongse


Thanks for the update.

The client was referring to the screenshot below

error.png

Issues/problems when retrieving prices for multiple countries please try the code I have attached and the below script:

https://refinitiv--c.documentforce.com/servlet/servlet.FileDownload?file=00P8Z00002FF8hVUAT&operationContext=S1


Can you please advise me further on the second part of your response as to how to enable logging into API? I don't quite know how to use the code you have provided.


Thanks in advance.

error.png (45.4 KiB)

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.