index error: too many indices for array

Hi,

ek.get_timeseries( ['BLX'], fields=['CLOSE'], interval = 'minute',start_date='2017-11-1T19:30', end_date='2017-11-1T19:35')

produces the error: *** IndexError: too many indices for array

It seems this is due to no data for 'BLX' in that period. But what's important is that the error causes the bulk request to throw exception (e.g. ek.get_timeseries( ['BLX','AA'], fields=['CLOSE'], interval = 'minute',start_date='2017-11-1T19:30', end_date='2017-11-1T19:35') ) which is not the case until this morning (2017-11-2T14:00 utc)

Can anyone explain?

Thanks

Best Answer

  • Hi @renee.yao,

    Since reporting this, I've attempted to run the get_timeseries() query again and observed expected behavior as documented. For example, if I request for the same data you are interested in where data is available, I get a response that looks like this:

    image

    When requesting for a timeframe where the data is not available, the get_timeseries() raises an exception as documented. For example:

    image

    The above output no longer provides the "too many indices for array" as we both initially observed but instead provides the expected output that "No data available...".

Answers

  • Hi @renee.yao,

    In general, these types of exceptions should not happen. I is likely an issue that needs to be resolved. I was able to replicate the issue.

    As a test, I changed the end date by one minute and received some data.

    image

    I will raise the issue with the team.

    thanks,