Missing candle data in websocket

at 11:03 in ‘NSE_EQ|INE155A01022’ on 23-02-2024

in fetch_market_data
    candle = data_dict['feeds']['NSE_EQ|INE155A01022']['ff']['marketFF']['marketOHLC']['ohlc'][1]
IndexError: list index out of range

Sorry for the delayed response. Could you provide us with the specific curl command for the candle data you’re attempting to retrieve? This will assist us in conducting an investigation.

Im using the websocket implementation code from python examples in github, it is working fine now only that day I was having missing data in response that too at specific time mentioned

1 Like

Happy to hear that. Please let me know if the issue occurs again.

Hello,

I had similar issue today for 40 seconds. I was able to capture the log from my program.

2024-02-27 11:06:41,079 - WARNING - get_ohlc_from_dict() - Total intervals received in 'i1_objects' are 1. Expected 2 for symbol NSE_FO|72239
2024-02-27 11:06:41,380 - WARNING - get_ohlc_from_dict() - Total intervals received in 'i1_objects' are 1. Expected 2 for symbol NSE_FO|72238

It seems to happen on any symbol where only 1 interval is received from the websocket.

The current workaround is to add validation on the number of intervals received.

Hope that helps.
Abhishek

1 Like