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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
7 1 1 3

eikon.eikonError.EikonError: Error code -1 | Port number was not identified. Check if Eikon Desktop or Eikon API Proxy is running.

I'm trying to get timeseries data in my local-django project, however when I'm trying to get the data I got this error message:

eikon.eikonError.EikonError: Error code -1 | Port number was not identified. Check if Eikon Desktop or Eikon API Proxy is running.

After creating a new app_key, I have write a lite code in Jupyter in order to understand if my connection works well, and this is what I get:

2020-09-03 09:32:22,231 P[5920] [MainThread 28020] Reset a Desktop session with new app_key 
2020-09-03 09:32:22,232 P[5920] [MainThread 28020] Unlock login_event for streaming session 0 due to stop streaming call 
2020-09-03 09:32:22,245 P[5920] [MainThread 28020] Checking port 9060 response : 500 - {"code":500,"message":"Cannot find module \".\"","statusMessage":"Internal Server Error"} 
2020-09-03 09:32:22,246 P[5920] [MainThread 28020] Port 9060 was retrieved from .portInUse file 
2020-09-03 09:32:22,246 P[5920] [MainThread 28020] Try to handshake on url http://localhost:9060/api/handshake... 
2020-09-03 09:32:22,421 P[5920] [MainThread 28020] Response : 200 - {"access_token":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJBcGlWZXJzaW9uIjoiMSIsIkFwcEtleSI6Ijc1ZGM2YzkzZjRlNTQ4MTU5OGU0MmI5NDBlZmY2YTJlZGZiODhkNzQiLCJBcHBTY29wZSI6InJhcGkiLCJMaWJyYXJ5TmFtZSI6IkVpa29uIFB5dGhvbiBMaWJyYXJ5IiwiTGlicmFyeVZlcnNpb24iOiIxLjEuNSIsImlhdCI6MTU5OTExODM0MiwiZXhwIjoxNjAwMzI3OTQyfQ.l7lJmXeGNotyvrr0B3j1yJ-CwNYCHLeC2RO1ATbN0FY","expires_in":1209600,"token_type":"bearer"} 
2020-09-03 09:32:22,422 P[5920] [MainThread 28020] Application ID: <my_app_key> 
2020-09-03 09:32:22,422 P[5920] [MainThread 28020] Init a Desktop session with new app_key 
2020-09-03 09:32:22,423 P[5920] [MainThread 28020] Port 9060 on local proxy was detected 
2020-09-03 09:32:22,424 P[5920] [MainThread 28020] entity: TimeSeries 2020-09-03 09:32:22,425 P[5920] [MainThread 28020] payload: {'rics': ['AAPL.O'], 'fields': ['CLOSE', 'TIMESTAMP'], 'interval': 'daily', 'startdate': '2020-07-30T00:00:00', 'enddate': '2020-08-31T00:00:00'} 

but I get some data.

However if use the same code in the Django project I get this error

eikon.eikonError.EikonError: Error code -1 | Port number was not identified. Check if Eikon Desktop or Eikon API Proxy is running.

I'm running the django application server on PORT 8080, if I remember well Eikon use the 8000

python manage.py runserver 8080

Thank you for your help.


eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpythonport-number
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.

Upvotes
Accepted
39.2k 75 11 27

@c.aydemir

Thank you very much for your feedback. We believe we identified the root cause of the problem, which manifests with Python 3.8+. The root cause happened to be in the dependencies of Eikon Data APIs for Python library (requests-async, http3 and nest-asyncio).
The problem has been addressed in Eikon Data APIs for Python library v1.1.6, which is now available on PyPI. Would you be so kind as to upgrade eikon module on your machine to v1.1.6 and see if it works? I'd very much appreciate if you could post your experience back on this thread.

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.

Thank you Alex and all! After updating the Eikon API to v1.1.6 the download works fine.

Once again thank you all for your support.


Upvotes
6.7k 8 6 7

Hi @c.aydemir What version of Eikon library and Eikon are you using? Some users have been experiencing issues with eikon library 1.1.4/1.1.5 and eikon 4.0.52. Please could you try dropping back eikon library to 1.1.2 (pip install eikon ==1.1.2) and let me know how you get on.

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.

Upvotes
4.3k 2 4 5

Hi,

Could you also detail which version of Python you're using ?

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.

Upvotes
7 1 1 3

I'm using:

- eikon==1.1.5
- Python 3.8.1
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.

@c.aydemir have you had a chance to try with eikon v1.1.2? thx

Yes, but it doesn't work.

This is the error that I get:

Error on checking port 9000 : HTTPConnectionPool(host='localhost', port=9000): Read timed out. (read timeout=20.0)
Error on checking port 9000 : HTTPConnectionPool(host='localhost', port=9000): Read timed out. (read timeout=20.0)
Error on checking port 36036 : HTTPConnectionPool(host='localhost', port=36036): Max retries exceeded with url: /api/v1/data (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x0E574460>: Failed to establish 
a new connection: [WinError 10061] No connection could be made because the target machine actively refused it'))
Error on handshake port None : Failed to parse: http://localhost:None/api/handshake
2020-09-03 11:52:00,037 P[33520] [Thread-1 29232] Error: no proxy address identified.
Check if Eikon Desktop or Eikon API Proxy is running.
2020-09-03 11:52:00,038 P[33520] [Thread-1 29232] Port number was not identified, cannot send any request
2020-09-03 11:52:00,038 P[33520] [Thread-1 29232] Port number was not identified.


@c.aydemir Can i ask again what version of Eikon you are running? thx

Show more comments
Upvotes
4.3k 2 4 5

Hi,

eikon 1.1.6.post1 was just released and is available on pypi.org.

You can update with "pip install --upgrade --no-cache-dir eikon"

It should fix issues with Python 3.8


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.

Upvotes
1 0 0 0

The combination Python 3.8.5, Python library v1.1.6.post2 and Eikon desktop v4.0.52 is not working for me.

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.

Hi,

One dependency introduced a breaking change last Monday: httpx 0.15

If you have this version, a workaounr is to downgrade to 0.14.2 (pip install httpx==0.14.2)

An eikon 1.1.6.post3 will published soon to fix it

Upvotes
1 0 0 0

Hi @pierre.faurel downgrading to httpx v0.14.2 solved my issue. (pip install httpx==0.14.2)

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