Upgrade from Eikon -> Workspace. Learn about programming differences.

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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
16 0 1 3

A question about Eikon api

I set a scheduled task to obtain multiple types of data at eight o 'clock every day. Today, I found out whether the data acquisition failure was caused by obtaining multiple types of data at the same time

error info: pyeikon json_requests.py:145:HTTP request failed: unknown async library, or not in async context

eikon-data-api#technology#product
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.

@joneliu

Hi,

Thank you for your participation in the forum.

Are any of the replies below satisfactory in resolving your query?

If yes please click the 'Accept' text next to the most appropriate reply. This will guide all community members who have a similar question.

Otherwise please post again offering further insight into your 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

Upvote
Accepted
78.8k 250 52 74

@joneliu

Thank you for reaching out to us.

I searched this error on Google and found that this error is from the underlying library.

1691471731600.png

Does this issue happen randomly or all the time?

You can enable logging in the API by using the below code to verify the problem.

import eikon as ek
ek.set_log_level(1)

1691471731600.png (107.4 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
16 0 1 3

after this, when sends request, no any response

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
16 0 1 3

it happen all the time , Now I restart application to resolve this problem , but I can't always restart ,so I need solution for this problem

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.

@joneliu

To find the cause of this problem, I need to replicate this issue on my machine.


Can you share the cut down version of your application and steps to replicate this problem?

[INFO:2023-08-15 13:31:48,460] pyeikon session.py:378:Send GET request to http://127.0.0.1:9060/api/status to detect API Proxy...

after this info,no any response

data, err = ek.get_data(instruments=code, fields=[
 "TR.RICCode",  "CF_NAME",  "TR.IPODate",  "CF_CURR",  "TR.AssetCategory",  "TR.ShareClass",  "CF_LOTSIZE", # "TR.PriceOpen",     # "TR.PriceClose",     "CF_DATE",  "CF_TIME",  "OPEN_PRC",  "HST_CLOSE",  "CF_CLOSE",  "TR.CompanyMarketCap",  "TR.PE", "TR.DividendYield" ])

Hi @joneliu ,

Could you please try enabling the logging in the API by using the below code, as mentioned by my colleague, to verify the problem.

import eikon as ek
ek.set_log_level(1)

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.