For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
646 6 13 25

eikon python module 1.1.2 behavior change

After an upgrade from 1.0.1 to 1.1.2 Eikon module prints debug data to console.

How can I stop it?


[EikonPHistory] There are 95 sub-tasks. Starting one...

2020-08-14 12:22:30,997 P[33500] [MainThread 17808] Request:{'Entity': {'E': 'TimeSeries', 'W': {'rics': ['AZTECACPO.MX'], 'fields': ['VOLUME;VALUE;', 'TIMESTAMP'], 'interval': 'tick', 'startdate': '2020-08-14T20:00:00', 'enddate': '2020-08-14T20:10:00'}}}

2020-08-14 12:22:31,548 P[33500] [MainThread 17808] HTTP Response code: 200

2020-08-14 12:22:31,548 P[33500] [MainThread 17808] HTTP Response: {"timeseriesData":[{"dataPoints":null,"errorCode":"TSIError","errorMessage":"Error: TSINoDataAvailable, ErrorCode: TA-TSINoDataAvailable, Fault: TSIError, Description: No data available for the requested date range","ric":"AZTECACPO.MX","statusCode":"Error"}]}

2020-08-14 12:22:31,553 P[33500] [MainThread 17808] Error with AZTECACPO.MX: No data available for the requested date range

2020-08-14 12:22:31,553 P[33500] [MainThread 17808] AZTECACPO.MX: No data available for the requested date range |


I have this line in the code:

ek.set_log_level(eklogin.DEBUG)

But this enabled the logging to the file. I still need it.

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpython
icon clock
10 |1500

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

1 Answer

Upvotes
Accepted
4.3k 2 4 5

Hi,

By default, debug info are also sent to stdout.
To disable this, one solution is :

import logging

...

ek.set_app_key("your app key")
logger = logging.getLogger("pyeikon")
logger.propagate = False

Then, you won' have no more debug output except in the log file.

icon clock
10 |1500

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

Click below to post an Idea Post Idea