Eikon API error with Spider 3.3.3.

I recently reinstalled Spider with the newer 3.3.3 version and then executed pip install eikon from Anaconda Navigator 1.9.7 shell, which went fine. However while importing ek from a console, I am getting error, as shown below. This was working perfectly earlier.

from eikon import ek

Traceback (most recent call last): File "<ipython-input-2-d37fe12a15bf>", line 1, in <module> from eikon import ek ImportError: cannot import name 'ek' from 'eikon' (C:\Users\Admin\Anaconda3\lib\site-packages\eikon\__init__.py)

Appreciate any help to get me back on track.

Best Answer

  • Alex Putkov.1
    Answer ✓

    @lebenjohnson.mannariat
    I think you got confused. The statement

    from eikon import ek
    could have never worked. It's an erroneous statement. The name 'ek' is not defined in eikon library and it never was. What you must have meant to use is
    import eikon as ek
    as @jirapongse.phuriphanvichai pointed out. The latter statement is a customary way of importing eikon library into your Python module.

Answers