question

Upvotes
Accepted
1 0 0 2

Datastream API is intermittently giving a Read Timed Out error

We have a number of jobs that use the Datastream API at the same time. They will each pull data (sometimes the same data) to calculate different models.

We will intermittently get a "Read Timed Out" error:

```
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='product.datastream.com', port=443): Read timed out. (read timeout=None)
```

This is very hard to replicate and only started happening in the past two weeks, but is now getting worse.

Many of our models are unable to run because of this. If we run models individually it seems to work. it seems to fail when they run at roughly the same time, or within a close interval.

Is there IP or API key throttling or rate limiting for the datastream api?

Has anything changed recently with the networking setup? (we experienced a similar problem with dsws afew months ago that was a result of datastream server config changes)

Is there any additional information I can provide to debug this?

python#technologyapidatastream-apidsws-apidatastreamtime-out
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 @Walter Cavinaw ,

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?
If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,
AHS

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.

Thanks,


AHS

1 Answer

· Write an Answer
Upvotes
Accepted
79.2k 251 52 74

@Walter Cavinaw

Thank you for reaching out to us.

It is the HTTP timeout. The server may need more time to process the requests.

The default HTTP timeout value of the DatastreamPy 2.0.21 library is 300 seconds while the older version is 180 seconds.

Please check the version of the DatastreamPy library and upgrade to 2.0.21 if you are using the older version.

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.

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.